Jira script runner check a custom field then edit another?


I'm currently trying to make a script to no avail.

I have two custom fields one called "Resolution level" and the other "Resolved by".
I need a way for when a ticket transitions from "open" to "resolved", it checks the resolution level and if its "None" it sets the "Resolved by" field to be empty.

1 answer

0 vote

This needs a little clarification:

When you say "from "open" to "resolved"" - I assume you want a post-function script? (it's the most simple approach for this, as it'll just need an "if/then set field" block of code)

Is the resolution level a select list?  If so, is this "none" JIRA's display for "empty", or is it an option in your list?

Is "Resolved by" a user-picker field or text? 

Hi Nic,

Resolution level is a select list, it goes from "None" then "1" "2" "3".

Resolved by is a custom field User Picker (single user).

Sorry, I was not clear on how to answer the first one - is "none" an option you've added or is it the system "none"?  If you go to edit the list of options, do you only see 1, 2 and 3 as options?

Hi Nic,

I see "None" as an option, I believe it is an option we added.

Suggest an answer

Log in or Join to answer
Community showcase
Louis De Jaeger
Posted Thursday in Off-topic

Friday fun: your best joke

Hi all Lets make this Friday fun really fun and post one (or more) of your best jokes! The joke can be about an Atlassian product, or just a really fun joke you want to share! I’m not the best j...

189 views 12 3
Join discussion

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
Atlassian Team Tour

Join us on the Team Tour

We're bringing product updates and pro tips on teamwork to ten cities around the world.

Save your spot