Is there a way to prevent a user from assigning an issue to themselves for a follow on status?

Crazy Cam
I'm New Here
I'm New Here
Those new to the Atlassian Community have posted less than three times. Give them a warm welcome!
May 26, 2021

I am trying to make sure a developer cannot progress a jira all the way through the workflow on their own.  I want to prevent then from say moving an IR from In Progress to In Code review and assigning themselves as the code reviewer.

I have a transition where the screen will pop up requesting an assignee (of course it populates with themselves if its already assigned to them) but I want to ensure they pick someone other then themselves to transition to the next status.  Is that possible?  I can't figure out which condition, validator, or post condition to use.

thank you

3 answers

0 votes
Suprija Sirikonda _Appfire_
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
May 27, 2021

Hi @Crazy Cam ,

You can achieve your requirement using JMWE add-on.

Add a "Scripted (Groovy) Validator (JMWE app)" validator on the transition.

If the "Assignee" field is mandatory during the transition and it should not be the current user, then add the below Groovy Script : 

!!issue.get("assignee") && !currentUser.equals(issue.get("assignee"))

Assignee(mandatory).png

Else, if the "Assignee" field is not mandatory during the transition, but if entered, then it should not be the current user, then add the below Groovy Script : 

!issue.get("assignee") || !currentUser.equals(issue.get("assignee"))

Assignee(not mandatory).png

Hope this helps!

Regards,

Suprija 

0 votes
Vikrant Yadav
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 26, 2021

Hi @Crazy Cam You can do this easily by putting condition in workflow. 

First move all developers to a particular project role like Developers project role.  Then put condition on the transition which you dont want to allow them. 

This option is only available in codition when JSU plugin in installed in JIRA .

User in role.PNG As @John Funk  said if have any other plugin like Script Runner or JWME you can use those also for putting condition. 

 

Thanks

0 votes
John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 26, 2021

Hi @Crazy Cam  - It will probably take an add-on like JWME or ScriptRunner to be able to control that. 

John Funk
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 27, 2021

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events