cancel
Showing results for 
Search instead for 
Did you mean: 

User Task where is it?

esseti
Champ in-the-making
Champ in-the-making
Hello all.
(i thought i posted something but indeed i didn't).
so:
i've copied the first example

  <process id="financialReport" name="Monthly financial report reminder process" isExecutable="true">
    <startEvent id="theStart"></startEvent>
    <sequenceFlow id="flow1" sourceRef="theStart" targetRef="writeReportTask"></sequenceFlow>
    <userTask id="writeReportTask" name="Write monthly financial report" activiti:candidateUsers="kermit">
      <documentation>Write monthly financial report for publication to shareholders.</documentation>
    </userTask>
    <sequenceFlow id="flow2" sourceRef="writeReportTask" targetRef="verifyReportTask"></sequenceFlow>
    <userTask id="verifyReportTask" name="Verify monthly financial report" activiti:candidateGroups="management">
      <documentation>Verify monthly financial report composed by the accountancy department.
              This financial report is going to be sent to all the company shareholders.</documentation>
    </userTask>
    <sequenceFlow id="flow3" sourceRef="verifyReportTask" targetRef="theEnd"></sequenceFlow>
    <endEvent id="theEnd"></endEvent>
  </process>
[code]
https://dl.dropboxusercontent.com/u/4628172/Screen%20Shot%202014-10-31%20at%2016.38.38.png
https://dl.dropboxusercontent.com/u/4628172/Screen%20Shot%202014-10-31%20at%2016.38.46.png

i deployed it, it has a task pending, but i don't see it.

where's the problem?

10 REPLIES 10

jbarrez
Star Contributor
Star Contributor
Where do you want to see it? In code? In Explorer?

After you deployed it, you need to start a process instance. A user task will then be ready for user 'kermit'.

esseti
Champ in-the-making
Champ in-the-making
It was "stuck", i re-run tomact and after that it appeared.

Now it works fine.

Just one question: when one completes a form, each field of the form is stored as a variable in the process?

jbarrez
Star Contributor
Star Contributor
Correct. You can however, intercept the form submit and do processing on it and choose which vars and how they are persisted.

esseti
Champ in-the-making
Champ in-the-making
How can i do the processing?
is there a way to do it in the configuration or do i've to do it with a script task or with some java logic?

what i need to do is to take the variable from the form and insert into a variable, named "data" that is a json object
basically, if the form has the field "url", which the user sets as "www.example.com"
the result should be
data.url = "www.example.com" (in this form data = {"url":"www.example.com"})
right now it's
url = "www.example.com"

esseti
Champ in-the-making
Champ in-the-making
Hello, thanks.
One thing (i thought i already posted this question in this thread):
is it possible to store the variabale within a json? or what's the best way to do it?

example:
- form with field URL
- when user fills in the URL there will be URL variable in the execution.
Now i need to have this URL variable inside another vatrible called DATA.
this DATA varible should be a JSON, it can be also fine if it's a JAVA objcet that later can be cast to JSON Object/array. How should i do?

Is there a direct mapping that i can use? Maybe some config in the form that i don't know? (like variable set as data.URL)

or should i use a script task to do the transformation?

anything that can help me on this?

Thanks.

jbarrez
Star Contributor
Star Contributor
There are two ways, either plug in your own form property type (http://activiti.org/userguide/index.html#formProperties)

or add a java service task / script task that does exactly that: creating the json object and storing it as a variable.

deva
Champ in-the-making
Champ in-the-making
I am getting only 10 tasks through activiti rest api. How could i get list of all tasks

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi

use
http://www.activiti.org/userguide/#N1316C


start 0 Parameter to allow for paging of the result. By default the result will start at 0.
size 10 Parameter to allow for paging of the result. By default the size will be 10.

Regards
Martin

deva
Champ in-the-making
Champ in-the-making
HI
  I am using activi rest with php. I can't able to get the start variables of the deployed process. Can you help me?