Possible to force fill in custom field as required to change a status to "QA review"?


Just wondering if there is a way to force a developer to fill in/complete a custom field such as "Fix version" as an requirement before they can change bug status (status transition) to "QA Review"? This status is when the QA would regress the fix for the bug claimed to fixed by the developer.

I looked under Workflows/Transitions > Conditions and post functions and you can't seem to do it this way. Also attempted to set "Fix version" field under custom fields for "Required" and the "Fix version" is required for all screens (even when you create a new issue). So I thought customing within transition level would be easier than custom field level.

Does anyone have any ideas/suggestions how to implement this? 

 Thanks you for your help and assistance on this matter. 








4 answers

You can do this with a custom script; I have similar ones to ensure that, at "Close" time, all versions listed in Fix Version/s are flagged as verified, against a "Verified Version/s" custom field.  You'd make it a custom validator on the "QA Review" transition in the workflow, something like:

import com.atlassian.jira.issue.Issue
import com.atlassian.jira.ComponentManager
import com.atlassian.jira.issue.CustomFieldManager
import com.atlassian.jira.issue.fields.CustomField
import com.atlassian.jira.project.version.Version
import com.opensymphony.workflow.InvalidInputException
import org.apache.log4j.Category

def Category log = Category.getInstance("com.onresolve.jira.groovy.PostFunction");

ComponentManager componentManager = ComponentManager.getInstance()
CustomFieldManager customFieldManager = componentManager.getCustomFieldManager()
CustomField fixVersionCF = customFieldManager.getCustomFieldObjectByName("Fix Version")

List<Version> fixVersions = issue.getCustomFieldValue(fixVersionCF)

if(fixVersions == null) {
        invalidInputException = new InvalidInputException("Fix Version is required for this transition.");

If all you want to do is make that field required for that specific transition, you can use a validator. Go to the desired step in the workflow and select the Validators tab. Choose Add Validator and select the Field Required option. Depending on what version oif JIRA you are using, you can either select the just field you want (Fix Version) or select the field and add a custom error message. 

Good point; my validator was actually comparing fields, I simplified it for this example. I forgot that the simplified version is built-in.

 @Kathy Tempesta - Thanks for your input, I've attempted your suggestion and I have 3 options related to permissions of the user and nothing related to "Field required". Is this correct? Do I need to do something else for this "Field required" option to appear?  


Screen Shot 2015-10-27 at 11.06.52.png

Here below is the previous screen before to you some context for the transition at hand.


Screen Shot 2015-10-27 at 12.27.13.png


Thanks for all of your help on this matter. 



Sorry, I didn't realize that was from an add-on but fortunately, it's a free one. You need to install JIRA Suites. It has a ton of really useful stuff in it, including the Required Field Validator option.


Once you have it, you will wonder how you ever lived without it (and no, I don't work for the developer smile).


Suggest an answer

Log in or Sign up to answer
Community showcase
Published Jan 08, 2019 in Jira

How to Jira for designers

I’m a designer on the Jira team. For a long time, I’ve fielded questions from other designers about how they should be using Jira Software with their design team. I’ve also heard feedback from other ...

1,132 views 4 9
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