09-25-2017 05:18 AM
Hi Team,
I designed a simple process like as below. here we have two user tasks. each task has frame with some fields.
I am using this process in spring framework. i started the process by using
runtimeService.startProcessInstanceByKey("additionJavaExample");
at start event.
In my spring controller, display the page for user inputs ( taking two numbers for addition ) when the process started. after getting inputs for first user task, how can i pass those values to that?
I am new to activiti framework here please help me out this.
09-25-2017 08:04 AM
Hi!,
Use a script task with the calculous, p.e.:
In Script Task (javascript):
var n1 = execution.getVariable("numberone");
var n2 = execution.getVariable("numbertwo");
var res = parseInt(n1) + parseInt(n2);
execution.setVariable("varRes", res.toString());
In form Result:
Best regards,
fegor
09-25-2017 08:21 AM
Thank you for your reply
Explore our Alfresco products with the links below. Use labels to filter content by product module.