Details
-
Bug
-
Status: Done
-
High
-
Resolution: Fixed
-
4.3.15
-
None
-
None
-
JIRA v7.*
-
0.6
Description
Steps to reproduce
0. Create a Multi User Picker custom field with name Multi User Picker
1. Set up a behaviour for field Description
2. Select writable
3. Add a condition: except Current user in user custom field value Multi User Picker
Result The description field remains writable even if the current user is part of the Multi User Picker field.
Workaround
Instead of setting the condition from the UI, script it. For example
def currentUser = ComponentAccessor.getJiraAuthenticationContext().getLoggedInUser() def description = getFieldById(getFieldChanged()) def cf = ComponentAccessor.getCustomFieldManager().getCustomFieldObjectByName("Multi User Picker") if (currentUser in underlyingIssue.getCustomFieldValue(cf)) { description.setReadOnly(true) } else { description.setReadOnly(false) }
For more examples on how to create scripted conditions