How to make Resolution required, without defaulting it?

Phyllis Davies January 30, 2020

I want to make sure that each issue is given a meaningful resolution when moved to done. I've created a screen ("Get Resolution") and attached it to each workflow transition that move to a "done" state. The field Resolution is a required field. So far so good.

My problem is that, on the transition screen, the Resolution field defaults to the first option (for example "code fixed"). Most people will simply save that value, I want the screen to force them to make an active choice rather than passive.

I tried using the post-validation that the field had been changed, but this always passes (I believe because it changes from empty to whatever they pick, including the default). So I have changed the first resolution to "Please select" so that it defaults to  that and I will at least be able to find issues where they did not make a "real" choice and fix them after the event.

I was hoping that I could validate Resolution is not "Please Select" but I cant see a way to do that. I also looked (unsucessfully) for properties to let me set the value pre-transition which would force the "has changed" validator to activate.

The only thing I can think of is two transitions, one to actively set the resolution to "Please Select" and then the other, with the screen, to validate that the user changed it. However unless I can trigger the second transition from the first then I'm I'm relying on the user to pick two transitions in a row, which is not a great interface, I can see how I could make that trigger happen automatically?

I'm out of ideas, anyone inspired?

2 answers

1 accepted

1 vote
Answer accepted
Jack Brickey
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 30, 2020

Check that you do not have a default value for your resolution field.

Jira settings > Issues > Resolutions

at the top you will have a link to "Clear defaults"

Phyllis Davies January 30, 2020

Ah its the simple things in life! I just didn't see that you could clear that default. I've now been able to remove my workarond "Please select" option and guess what - Jira makes it say "Please select". Perfect! Thanks.

Jack Brickey
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 30, 2020

Yes it is rather non-obvious. glad it worked for you.

0 votes
Ganesh Babu
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 30, 2020

Hi @Phyllis Davies 

Welcome to the Atlassian Community..!!!

Technically, it's not "mandatory" in Jira speak. The field is optional, otherwise you'd have to have it on the create screen, which would be pretty useless. Your problem is that when you do place the field on a screen, it does not have an "empty" option, and defaults to the first value in the list, so you always end up setting it to something.

To "fix" this, you need to do two things:

  1. Open up the application server installation in a file manager, find the template files that render resolution, and change them to forcibly add the "none" to the list. Do this while JIRA is offline of course, and keep a backup (i.e. do it in test first and check it works). The file used to be called resolution-edit.vm, but it may have moved or been renamed
  2. Now you've added the empty option, you will now find that the resolution is optional and the users can use the null option to leave it blank.  So you need to add a validator to make it mandatory for them to fill it in.

Note also that point 1 will let people mess up your resolutions in quick-edit if you place the field on the "edit" screens, so the standard advice to "never put resolution on an edit screen" still stands.

And more or less is that we need to educate them to follow few things...!!! Resolution needs to be set, which would help us to understand the overview of an issue. I hope this is the best way rather making things difficult for ourself.

Suggest an answer

Log in or Sign up to answer