Hi,
I try to set an MultiGroupPicker custom field with multiple groups. The setting with 'setCustomFieldValue' works fine.
... List<Group> accessGroups = (List<Group>) mutableIssue.getCustomFieldValue(multiGroupCf); if(accessGroups != null) { accessGroups.add(groupManager.getGroupObject(it)); //set custom field mutableIssue.setCustomFieldValue(multiGroupCf, [accessGroups]); } ...
But if I update the issue with
ComponentAccessor.getIssueManager().updateIssue(currentUser, mutableIssue, EventDispatchOption.DO_NOT_DISPATCH, false);
I get the following error
... java.lang.ClassCastException: java.util.ArrayList cannot be cast to com.atlassian.crowd.embedded.api.Group ...
Maybe someone can help me with this problem.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.