How to transition issue if radio button field has certain value?

Vera Henrichs
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.
October 6, 2015

Hello,

I'm looking for a way to transition an issue from Resolved to Closed, only when a required custom field with radio buttons has a certain value (and maybe some other conditions). I don't see that possible in JIRA. 

I've tried the free plugin Workflow Enhancer for JIRA, but it doesn't work. I guess because of the boolean-option vs radio buttons wink

And I've tried the free trial of the plugin Enhancer Plugin for JIRA but that has conditions that are not even close to what I want...

So... any ideas on other options or plugins? 

2 answers

1 accepted

1 vote
Answer accepted
Joe Pitt
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 6, 2015

I'm not familiar with that plugin. I use the JIRA suite utilities. It allows checking the value of a custom field as a condition for the transition. I've never tried to test for radio buttons. I normally use select lists for options. Check it out at https://marketplace.atlassian.com/plugins/com.googlecode.jira-suite-utilities

Vera Henrichs
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.
October 6, 2015

Could you do a quick check perhaps for me?

Vera Henrichs
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.
October 6, 2015

Ok, I was toooo curious so I installed it. And tried it. And enjoyed it! It does what I need: get every field a certain value to transition (or not, or bigger/smaller). Thank you!

2 votes
AndrewB October 6, 2015

Script Runner http://www.adaptavist.com/w/products-plugins/adaptavist-scriptrunner/scriptrunner-for-jira/

 

Two possibilities come to mind: either use a condition script or validator script.

  • Condition script can hide the Resolved->Closed transition if the radio button isn't set correctly.
  • Validator script can pop up an error message and prevent the transition from Resolved->Closed if the radio button isn't set correctly.

 

There are some built-in scripts and you can also create completely custom scripts. You can add in as many checks & conditions as you want if you need to check for other things as well.

 

There are probably other ways to accomplish this w/ Script Runner as well. Very easy to learn, flexible, and powerful. You should install the trial version and try it out. You might also be able to install an older (still very useful) version and continue use for free.

 

Hope it helps.

Vera Henrichs
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.
October 6, 2015

Hi Andrew, Thank you for your quick answer. I've already installed Scriptrunner a while ago, but never used it besides the built-in scripts. Your second option is actually the one we really want, never thought it could do something like that. Looks exciting but hard to learn, do you have any tips for learning?

AndrewB October 6, 2015

I'd start by reading through the documentation here: https://scriptrunner.adaptavist.com/latest/jira/quickstart.html. Then I'd go over https://scriptrunner.adaptavist.com/latest/jira/custom-workflow-functions.html#_validators a few times. These scripts can be done directly in a console in JIRA so they're very easy to get up and running. Copy one of the examples, get that to work, and then move on to creating your own. If you have trouble writing the script then create another post on the forums and people will help out.

Vera Henrichs
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.
October 6, 2015

Tnx!

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events