[jboss-user] [jBPM] - IdentityService implementation

Walter Seymore do-not-reply at jboss.com
Tue Jun 8 03:38:58 EDT 2010


Walter Seymore [http://community.jboss.org/people/WalterJS] replied to the discussion

"IdentityService implementation"

To view the discussion, visit: http://community.jboss.org/message/546666#546666

--------------------------------------------------------------
This is what I use the populate the dropdown in my reassignment screen:

Get the participations like Michael suggested or through an hql query and then loop through the them to find the users:

    for (Participation participation : participations) {        if (participation.getUserId() != null) {            users.add(participation.getUserId());        }        else if (participation.getGroupId() != null) {            List groupUsers = noTxCmdService.execute(new FindUsersInGroupCmd(participation.getGroupId()));            if (groupUsers != null) {                for (User groupUser : groupUsers) {                    users.add(groupUser.getId());                }            }        }    }   




FindUsersInGroupCmd:

    public List execute(Environment environment) {        IdentitySession identitySession = environment.get(IdentitySession.class);        return identitySession.findUsersByGroup(groupId);    }


Hope  this helps
Walter

--------------------------------------------------------------

Reply to this message by going to Community
[http://community.jboss.org/message/546666#546666]

Start a new discussion in jBPM at Community
[http://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20100608/c3586779/attachment.html 


More information about the jboss-user mailing list