W.hen Creating a particular issue "manually" we are requiring an issue link.
We also want to create the issue automatically from another Issue type transition. Due to the mandatory link requirement I am in a "chicken and egg" situation.
I would like to add to my script (scriptrunner) validator that checks for the links, to only validate the link when the "created from" issue is not a specific issue type.
I was trying to use getContextIssue, but this seems to only be available from behaviors, not workflows.
So when "Created From" = Issue type X, then do not validate links. If "Created From = null, then check for links.
I was going down this path, but getContextIssueId() does not resolve
def issueManager = ComponentAccessor.getIssueManager()
def cfId = getContextIssueId()
def contextIssue = issueManager.getIssueObject(cfId)
Any thoughts?