How to set a validator on create issue to force a certain type of priority based on a component?

I would like to force a reporter to select type of priority based on the component he have selected when he create the issue.

The condition should be:

If the selected Component/s is 'CS Internal', reporter must select Priority CS1, CS2 or CS3 (and not any other priority type)

Component/s and Priority are system field

Custom script validator with groovy script can help here.

Any advise will be appreciated.

2 answers

1 accepted

Hi Shai,

You can do it using "Boolean validator with math, date-time or text-string terms" validator (provided by JIRA Workflow Toolbox) in transition "Create Issue" using the following configuration:

Captura de pantalla 2016-01-24 a las 21.58.42.png

Boolean expression is:

%{00094} ~ "CS Internal" IMPLIES %{00017} in ["CS1", "CS2", "CS3"]

Note that:

  • %{00094} is field code for field "Components"
  • %{00017} is field code for field "Priority"

 

Once configured, transition "Create Issue" will look like this:

Captura de pantalla 2016-01-24 a las 22.05.01.png

Regards,

Fidel Castro Armario

Thank you Fidel, you were spot on as always.

Resolution works as expected.

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 Thursday in Jira

5 ways you can make the most of Jira Software and Bitbucket Cloud

As part of the Bitbucket product team I'm always interested in better understanding what kind of impact the use of our tools have on the way you work. In a recent study we conducted of software devel...

84 views 0 5
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