-
1. Re: Using OnEntry and OnExit in JBPM 5 Human task
salaboy21 Dec 27, 2011 3:38 PM (in response to vigneshbhaskar)1 of 1 people found this helpfulHere is an example:
And Demian's blog explain a little bit more about how to use this feature:
http://dcalca.wordpress.com/2011/09/03/on-enter-and-on-exit-node-actions-in-jbpm5/
Cheers
-
2. Re: Using OnEntry and OnExit in JBPM 5 Human task
vigneshbhaskar Dec 27, 2011 5:30 PM (in response to salaboy21)Thanks Mauricio for your reply, I followed the blog and added those onEntry and onExit entries in the bpmn xml. I was trying to retrieve the taskID from the workItemID using the following codes.
long workItemId = ((org.jbpm.workflow.instance.node.WorkItemNodeInstance)kcontext.getNodeInstance()).getWorkItem());
JBPMUtil.getTaskByWorkItemID(workItemId).getId();
I am able to retrieve the workItemId only on the onExit actionscript and not in the onEntry script. From the logger, i understand that the Task is created only after the onEntry script runs. I am still worried how i can send an email with the link pointing to the TaskID. Is there any alternative way of accomplishing this?
-
3. Re: Using OnEntry and OnExit in JBPM 5 Human task
stundzig Feb 20, 2013 10:53 AM (in response to vigneshbhaskar)Hi Vignesh,
do you have a solution for that? I would like to send a notification in the onEntryAction with the taskId too. But actually I don't know how to get it.
WorkItemNodeInstance.getWorkItemId() returns -1, because the item isn't created in onEntryAction.
Regards
Steffen...