Can the "Universal Validator" act on the Parent Status field?

I am using the "

Universal Validator" from the JIRA Workflow Enhancer. Works pretty well. But I have one thing I would like to do that I can't figure out how to.

My Issues have a custom field called "Parent Status" which as it sounds is the status of a subtask's parent. I would like to add a validation to the CREATE transition to block creation of subtasks if the parent is not in a particular status.

My real goal is to prevent the creation of subtasks for certain kinds of Issues.

Any ideas out there?

2 answers

1 accepted

Thanks. Yes, that is how I am doing it. But it is a real pain. For example, in most issue types, I have the "In Progress" status. But for the types where I don't want to have subtasks I have to add a new status, like "Progress Started" and then check status. Kludge. I was looking for something more straight forward.

Hi George, in fact there's a validator called "Parent status validator" in JIRA Misc Workflow Extensions plugin.

You can add this validation in the create transition and this will resolve your problem.

Theres a Built-in script in Script Runner plugin called

Allows the transition if this query matches a JQL query

So what you really are after is a workaround to this?

https://jira.atlassian.com/browse/JRA-7990

I am remiss in asking why a solution doesn't work, instead of discussing the problem. I was using "parent status" as a test field for my solution.

What I really want to do is block subtask creation for certain Issue types. I had planned to do it by looking at a field copied from the parent task. However, it appears (and is logical) that he field value is not available until after the subtask is created.

If the parent has unique status then that would work, for example:

If the parent you want to be able to have subtask has a status 'Testing' and only this issue type has this status then only this issue will be able to have a subtask since no other issue type has the possibility to be on that status.

Yup... That's a problem.. I've searched a while ago for some workaround for this but not been able to find out how to do it.

Maybe with that Script Runner script I mentioned above, you can ask with the JQL what issue type is the parent and then allow transition if it is the issue type you 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 16 hours ago in Off-topic

Get to know our Atlassian User Group Leaders from Bengaluru, India

Meet @Dinesh Dhinakaran, @Vishnu Vasudeva, @Rajeev Verma, and Jamshid Nalakath: Our extraordinary AUG leaders from Bengaluru, India. These four work together to strengthen the bonds of their local co...

116 views 0 4
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