Single user Actor Filter

1
0
-1

Hi, i would like to user the "Single User" Actor Filter.

I am storing the username of the user which i would like to assign the task on field.

How could i retrieve the Id from the username trought a script to put inside the "Single User" Actor Filter Id?

Thanks

1 answer

1
0
-1
  1. import org.bonitasoft.engine.api.IdentityAPI;
  2. import org.bonitasoft.engine.identity.User;
  3.  
  4. Long userid = identityAPI.getUserByUserName(userName.toLowerCase());
  5. return userid.getId());

regards
Seán

PS: As this reply answers your question, please mark as resolved.

Notifications