How do i transition an issue automatically based on usergroup?

We have a scrumproject where we want have issues on a kanban board first, where they can be reviewed by the PO or be set to low priority. After the PO has reviewed them they can be transferred to "open" and they will appear on the regular backlog.

This works like a charm and i can recommend it to anyone. But the PO would like one small change, when the scrumteam themselves (let's call them team test) create an issue (so no external users) they would like it to start in the "open" status, no review by PO necessary. I can automatically transition it based on a groovy script but how would i write such a script? that if the reporter is a member of team test it will automatically transition to "open"?

 

Thanks in advance!

1 answer

1 accepted

0 vote
Tarun Sapra Community Champion Aug 08, 2016

In Script Runner plugin there is a built-in post function script called

"Fast Track transition an issue" you can use that to transition an issue to open and configure a "condition" in groovy in that post-function that reporter belongs to a particular group

import com.atlassian.jira.component.ComponentAccessor
def groupManager = ComponentAccessor.getGroupManager()
groupManager.isUserInGroup(issue.reporter?.name, 'test')

That looks good, where in this script should i fill out the name of the group?

Is it where now 'business users' is typed?

 

Tarun Sapra Community Champion Aug 08, 2016

I have updated the script

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published yesterday in Jira

Mission-critical battery manufacturer fulfills FAA software requirements with Commit Policy Plugin

EaglePicher Technologies is a leading manufacturer of battery systems for diverse industries like defense, aviation, space or medical. As they operate in highly regulated industries, keeping a clear ...

155 views 0 2
Read article

Atlassian User Groups

Connect with like-minded Atlassian users at free events near you!

Find a group

Connect with like-minded Atlassian users at free events near you!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you