They have a condition if the reported is in a specific group:
import com.atlassian.jira.component.ComponentAccessor
def groupManager = ComponentAccessor.getGroupManager()
groupManager.isUserInGroup(issue.reporter?.name, 'business-users')
But how can i change this so it's the assignee?
Use assignee instead of reporter...?
I chaned it to:
def groupManager = ComponentAccessor.getGroupManager()
groupManager.isUserInGroup(issue.assignee?.name, 'External Art')
Getting error:
javax.script.ScriptException: groovy.lang.MissingPropertyException: No such property: ComponentAccessor for class: Script52
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You have to import it:
import com.atlassian.jira.component.ComponentAccessor
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Why does this not work when adding && issue.projectObject.key ==
'ABCD'
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.