cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple Assignees in Workflow

karimbuenaseda
Champ on-the-rise
Champ on-the-rise
Hi is there a way I could do a serial workflow in alfresco using Activiti?, I have tried to add this code into my activiti code but so far it does not make me assign my workflow to Multiple Assignees.


${bpm_assignees.properties.userName}


I also modified my model to reflect many assignees as true.

Any idea as to how I can do it?

Thanks,

1 REPLY 1

mitpatoliya
Star Collaborator
Star Collaborator
you need to change your model first to add bpm_assigness to given task
then add this block to that task


  <activiti:executionListener event="start" class="org.alfresco.repo.workflow.activiti.listener.ScriptExecutionListener">
                 <activiti:field name="script">
                        <activiti:string>
                           var members = people.getMembers(bpm_groupAssignee);
                           var memberNames = new java.util.ArrayList();
                          
                           for(var i in members)
                           {
                               memberNames.add(members.properties.userName);
                           }
                             execution.setVariable('wf_groupMembers', memberNames);
                           execution.setVariable('wf_reviewerCount', memberNames.size());
                        </activiti:string>
                     </activiti:field>



there might be few other steps you need to do but this will give you good start.