Related Issues Status Validator
A workflow validator which ensures that the current issue's related issues (such as linked issues, Stories of an Epic, Epic of a Story, subtasks of an issue, issues returned by a Groovy script or a JQL search, etc.) are in one of the specified statuses.
This post-function does not work with remote links (links to Jira issues residing on another Jira instance/server).
JMWE now considers "symmetrical" link types (such as "relates to") as one link direction instead of two on the configuration screens and in the validator execution.
To add 'Related Issues Status Validator' to a transition:
Click
Edit
for the workflow that has the transition you wish to configure the validator on.In the Workflow Designer, select the transition.
Click on
Validators
in the properties panel.Click on
Add
validator
.Select
Related Issues Status Validator
from the list of validators.Click on
Add
to add the validator on the transition.Select the related issues from
Which issue(s)
drop-downSelect the issue type from the
Issue Type
field, or leave it asAny
for any issue type.Select the status(es) the related issues must be in for the transition to be allowed from the
Statuses
field.Input a message in the
Error message
field to customize the error message.Click on
Add
to add the validator to the transition.
On the Service Management portal view of a request, the customer will not see the Error message
when the validator fails. This is due to a known limitation (JSDSERVER-5822) with Atlassian.
You are viewing the documentation for Jira Data Center/Server.
On This Page
When you add this validator to a transition and trigger the transition, the add-on checks the Status of each related issue. Based on the option selected under "Related Issues Status Validator#Mode" if the related issues do not satisfy the condition then an error message is displayed.
Which Issues
Select the issues to check the constraints on. They can be:
Linked issues: Select issue(s) linked to the current issue through any link type or a specific link type such as
blocks
,is cloned by
, etc.Sub-tasks of the current issue: Select this option to operate on the sub-tasks of the current issue
Parent issue of the current sub-task: Select this option to operate on the parent of the current issue
Issues that belong to the current Epic: Select this option to operate on the issues that belong to the current Epic
Epic of the current issue: Select this option to operate on the Epic of the current issue
Child issues of the current issue in the Portfolio hierarchy: Select this option to operate on the child issues of the current issue in the Portfolio hierarchy
Parent issue of the current issue in the Portfolio hierarchy: Select this option to operate on the parent issue of the current issue in the Portfolio hierarchy
Issues returned by a Groovy script: Input a Groovy script that returns either a single Issue object, or a Collection of Issue objects, or a String representing the key of an issue, or a Collection of Strings each representing an issue key. For example:
"TEST-1"
["TEST-1","TEST-2"]
ComponentAccessor.issueManager.getIssueObject("TEST-1")
[ComponentAccessor.issueManager.getIssueObject("TEST-1"),ComponentAccessor.issueManager.getIssueObject("TEST-2")]
issue.parentObject
issue.getLinkedIssues()
Issues returned by a JQL search: Input a JQL search expression, including an optional Groovy Template markup. For example:
project = TEST
returns issues of the project with the key TESTproject = ${issue.get("project").key} and assignee = ${
currentUser.name}
returns issues of the project the current issue belongs to and assigned to the current user.To operate on issues of a project with key
TEST
and issue type name same as the value in a text field<% if (issue.get("Single line text")) { %> project = TEST and issuetype = ${issue.get("Single line text")} <% } else { %> issuekey=INVALID-1 <% } %>
Mode
All issues must be in the selected statuses below: All the related issues must be in one of the status(es) selected under "Statuses"
At least one issue must be in one of the selected statuses below: At least one related issue must be in one of the status(es) selected under "Statuses"
No issue must be in one of the selected statuses below: No issue must in one of the status(es) selected under "Statuses"
At least one issue must not be in one of the selected statuses below: At least one issue must not be in one of the status(es) selected under "Statuses"
Validator scope
Control the execution of the validator using this option. Check this option if you want the validation to be performed only in certain cases, such as if the issue is of certain issue type or only if the issue is unassigned, or more generally satisfies an arbitrary Groovy expression.