I'm trying to get the username of a group of assignees in a workflow creation.
For assignees I made this:
ActivitiScriptNodeList assignees = (ActivitiScriptNodeList) execution.getVariable("bpm_assignees");
if(assignees == null) {
System.out.println("No assignees.");
} else {
for (ActivitiScriptNode personNode : assignees) {
String username = (String) personNode.getProperties().get("cm:userName");
listAssignees.add(username);
System.out.println("Username: " + username);
}
}
But for groups, the ActivitScriptNodeList not works.
How can I do this for bpm_groupAssignees?