Features used to implement the example
- Write field on linked issues or sub-tasks
- Block or hide a transition for an issue depending on its issue links
We add Write field on linked issues or sub-tasks to "Resolve Issue" transition on Story's workflow, in order to execute transition "*Resolved Issue*" on Epic issue. To do it we write the name of the transition into virtual field "Execute transition (delayed execution)". We use a boolean expression in order to check that the rest of the stories are already resolved or closed.
We add Blocking or hiding a transition depending on its issue links to "Resolve Issue" transition in Epic's workflow, in order to prevent Epic from being manually resolved while some of its Stories are still "Open" or "In Progress".
Example: Automatically resolve an epic when all its stories are resolved
We are going see how to implement a mechanism in our workflows, in order to auto-transition "Epic" to Resolved status when all its "Stories" become Resolved or Closed. Let's see in screenshots how to configure the different features.
We add Block or hide a transition for an issue depending on its issue links to "Resolved Issue" transition in "Epic's workflow:
Once configured, transition "Resolved Issue" in Epic's workflow will look like this:
We add Write field on linked issues or sub-tasks post-function to "Resolve Issue" transition in "Story's workflow:
Note that: if you are using Jira 7.0 or higher with versions of Jira Workflow Toolbox older than Release Notes for 2.2.8, you should input the following boolean expression in parameter Filtering by field values:
count(filterByStatus(filterByIssueType(linkedIssues("is Epic of"), "Story"), "Done, Closed, Resolved")) = count(filterByIssueType(linkedIssues("is Epic of"), "Story")) - 1
Once configured, transition "Resolved Issue" in Story's workflow will look like this:
This same configuration should be added to "Close Issue" and "Done" transitions in Story's workflow, in case direct closing is allowed for stories.
Other examples of that functions
Write field on linked issues or sub-tasks
- Add and remove a single or a set of items from multi valued fields
- Automatically become watcher of every issue blocking an issue assigned to you
- Automatically close resolved sub-tasks when parent issue is closed
- Automatically resolve an epic when all its stories are resolved
- Compose dynamic text by inserting field values in a text template
- Copy "Due date" into a date type custom field in a linked issue if it's greater than current issue's "Due date"
- Copy attachments from one issue to another
- Create a comment in sub-tasks when parent transitions
- Creating a Jira Service Desk internal comment
- Creating a Jira Service Desk internal comment on linked issues
- Execute transition in epic
- Make linked issues, sub-tasks and JQL selected issues progress through its workflows
- Moving sub-tasks to "Open" status when parent issue moves to "In Progress"
- Sum sub-task's "Time Spent" (work logs) and add it to a certain linked issue
- Transition sub-tasks when parent is transitioned
Block or hide a transition for an issue depending on its issue links