Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
badges earned

Your Points Tracker
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Linked Issue Validator


I need to be able to prevent a workflow transition based on the status of a linked ticket.

Main ticket is of one issue type and has a linked ticket of another issue type.

Transition of Main ticket from status A to status B should be allowed ONLY if the linked ticket is in the "Done" status.

I have tried utilizing the "Validation of linked issues" validator, properly (at least it looks right to me) setting up all the properties of the validator.

The result is: Moving the Main ticket from status A to B (as explained above) when the linked ticket is NOT in "Done" is not allowed by the validator (works as expected).

HOWEVER - Moving the Main ticket from status A to B when the linked ticket IS "Done" is also not being allowed by the validator (does NOT work as expected).

What am I missing? (I tried the same with "Condition" > same results)

2 answers

0 votes
Payne Community Leader May 25, 2021

If you have a scripting app, such as ScriptRunner or JMWE, you can use a validator script like we have done. 

import com.atlassian.jira.component.ComponentAccessor

//Outward links, where we'll find any "is linked to PCE" links
def issueLinks = ComponentAccessor.getIssueLinkManager().getOutwardLinks(issue.getId())
def numClosedPceIssues = 0

//Inward links, where we'll find any "is request for project" links
def inwardIssueLinks = ComponentAccessor.getIssueLinkManager().getInwardLinks(issue.getId())
def numProjectIssues = 0

def linkedObject

//check outward links for "is linked to PCE" links
for(IssueLink i in issueLinks)
//want only PCE links
if(i.getIssueLinkType().getName() == "PCE")
linkedObject = i.getDestinationObject()
//want only PCE issues with resolution of Complete
if(linkedObject.getIssueType().getName() == "PCE" && linkedObject.getResolution()?.getName() == "Complete")

//if there are no linked closed PCEs, check inward links for "is request for project" links
if(numClosedPceIssues == 0)
for(IssueLink i in inwardIssueLinks)
//want only Project links
if(i.getIssueLinkType().getName() == "Project Portfolio Link")
linkedObject = i.getSourceObject()
//want only Project issues
if(linkedObject.getIssueType().getName() == "Project")

return numClosedPceIssues > 0 || numProjectIssues > 0

I don't have a scripting app (I know...I know).

Is it possible to do with the native, built-in Validator?

Payne Community Leader May 25, 2021

Not that I know of, but maybe someone else will chime in with a way. :-) 

Just got it to work with the native Validator!!

it was a matter of setting up the right "direction" for the properties.

The key was to set up the "Issue link types" to the target ticket for which I want to check the status and indicate the "done" status.

I'm pretty sure I've tried that combination before, but who knows. It suddenly "started" working.

Thanks to all who read and thought about my question. :)

Payne Community Leader May 25, 2021

Great! Glad to hear.

Suggest an answer

Log in or Sign up to answer
Community showcase
Published in Confluence

Introducing External Collaboration for Confluence

We’re excited to introduce external collaboration for Confluence, now available in early access. It is available to preview for Confluence Cloud Premium and Enterprise customers. (If you're not on ...

218 views 0 8
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you