Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Updating an issue's due date based on sub-tasks' due dates and statuses

Aleksandra Gregec
Contributor
May 1, 2023

I have an automation that sets the due date of an issue to the earliest due date among its sub-tasks. However, I would like it to update when a sub-task is marked as done to the earliest due date of a sub-task that does not have the status 'done'. I tried it this way, but it does not seem to work:

jira2.jpg

jira3.jpg

1 answer

1 accepted

3 votes
Answer accepted
Trudy Claspill
Community Champion
May 1, 2023

Hello @Aleksandra Gregec 

Welcome to the Atlassian community!

Can you show us the rule you are using to originally set the due date of an issue to the earliest due date from its subtasks? 

Trudy Claspill
Community Champion
May 1, 2023

This rule will set the parent issue Due Date to the earliest Due Date of its sub-tasks that are not in a Done status. It will run when a sub-task status is changed to Done.

TRIGGER: Issue Transitioned
To Status: Done
CONDITION: Issue Fields Condition
Field to monitor: Issue Type
Condition: equals
Value: Sub-task
FOR BRANCH: Parent
ACTION: Lookup Issues
JQL: parent={{issue.key}} and status != Done
ACTION: Edit Issue
Field: Due Date
Value: {{lookupIssues.duedate.min}}
Aleksandra Gregec
Contributor
May 2, 2023

Hi Trudy, thank you very much! This was very helpful and it works :) Previously I used to set an automated comment when an issue transitions and that would trigger another automation which then changed the due date of the issue to the earliest one of the subtask, by setting it to  {{isse.subtasks.duedate.min}}. I also discovered lookup later but was missing this part parent={{issue.key}}, so all of the subtasks were taken into consideration. 

 

This helped and it works now, thanks!

Like # people like this
KL June 4, 2024

@Aleksandra Gregec LIFESAVER!! I've googled endlessly for this exact smart value logic because I don't have Lookup Issues component

{{issue.subtasks.duedate.min}}

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
FREE
TAGS
AUG Leaders

Atlassian Community Events