cancel
Showing results for 
Search instead for 
Did you mean: 

Troubles linking a form to a task

tobiasw_
Champ in-the-making
Champ in-the-making
Hi,

I watched http://www.youtube.com/user/ActivitiBPM?blend=6&ob=5 and tried to recreate a similar process:

I modelled the process and created deployment artifacts. I then imported screencast.bar with probe.

However, when I click on "complete form" under "my tasks",  I get a popup "Failure". Seems like it cannot find the file with the form.
This is what I entered under "form key:" for the particular task: /diagrams/request.form

My structure is:

-demoProject
–src/main/resources
—diagrams
—-request.form
—-screencast.activiti
—-screencast.bpmn20.xml

BPMN 2.0:

  <process id="Screencast" name="screencast">
    <documentation>Place documentation for the 'screencast' process here.</documentation>
    <startEvent id="startevent1" name="Start"></startEvent>
    <endEvent id="endevent1" name="End"></endEvent>
    <userTask id="request" name="Request task" activiti:candidateGroups="accountancy"[b] activiti:formKey="/diagrams/request.form"[/b]></userTask>
    <sequenceFlow id="flow1" name="" sourceRef="startevent1" targetRef="request"></sequenceFlow>
    <sequenceFlow id="flow2" name="" sourceRef="request" targetRef="endevent1"></sequenceFlow>
  </process>

I also tried: "diagrams/request.form" and "request.form" with same result.

I then opened the folder demoProject\src\main\resources\diagrams. I put everything in a zip file and uploaded it manually. The form.key was still request.form, but it finally worked.

Do you have any idea why my deployed bar file does not work in any scenario? Is it the path or is the request.form not part of the bar file? I do not really want to zip everything manually each time I need to deploy a change.

I would be grateful for any hints.

Best regards and thank you in advance,
Tobias
1 REPLY 1

jbarrez
Star Contributor
Star Contributor
Your form must always be part of the same deployment package (ie bar file) of your process, as the form resource is retrieved relative to the deployment.