AnsweredAssumed Answered

Workflow Custom Assignee using Activiti bpmn.xml file

Question asked by pankajnegi on Mar 6, 2012
Latest reply on Jun 19, 2012 by pankajnegi
Hello Friends,

I have tried to assign custom assignee as according to http://activiti.org,

http://activiti.org/userguide/index.html#bpmnUserTaskAssignment

it is possible to delegate to custom assignment logic using a task listener on the create event:

=>I made below userTask in the xyz.bpmn.xml file

<userTask id="task1" name="My task" >
  <extensionElements>
    <activiti:taskListener event="create" class="org.activiti.MyAssignmentHandler" />
  </extensionElements>
</userTask>

=>and create a class

public class MyAssignmentHandler implements TaskListener {

  public void notify(DelegateTask delegateTask) {
    // Execute custom identity lookups here
   
    // and then for example call following methods:
    delegateTask.setAssignee("kermit");
    delegateTask.addCandidateUser("fozzie");
    delegateTask.addCandidateGroup("management");
    …
  }
 
}

and put the jar  of this class into the path tomcat/webapps/alfresco/WEB-INF/lib

but its not working , not even finding any log for it


can anyone please tell me how will it work , or if any other solution for the same



Thanks
Pankaj

Outcomes