I'm trying to set up a 'Scripted (Groovy) Validator (JMWE app)' validator that checks if an issue of a certain project key was linked during creation of the issue. My script works fine when I test it against an existing issue in the editor, but fails to work during creation.
Any help would be greatly appreciated.
This is the script:
// Collect project keys of all linked outgoing issues
def issueLinkManager = ComponentAccessor.getIssueLinkManager()
def linkedKeys = issueLinkManager.getOutwardLinks(issue.id).destinationObject.projectObject.key
// Check if linked keys contains a DPO ticket
These are the validator settings with a successful test of an existing issue:
Error message on form even though a DPO ticket is linked:
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