Under my epic, I have parent tasks and sub-tasks within them.
I want a rule that every time I change or enter the start and end task to my child tasks, the parent task will update to the max and min start and end dates of the first and last child task within the parent task. I currently do not have any times entered except the child tasks.
I tried using this link but it didnt seem to work:
Hi @wiwan -- Welcome to the Atlassian Community!
First things first: I estimate this question / scenario is asked about 2-3 times per week in the community, with many responses over the years. And that article you note covers a very narrow scenario to update a parent issue for changes to a child issue. It does not cover all possible cases (or even the edge cases in the article). For example, the article covers one pair of parent-child relationships, and not two as you describe: Epic-to-Task, and Task-to-Subtask.
If your rule does not work, it may not match the scenario, or if it does match, the rule may not have been implemented to match the article.
For a question like this, context is important for the community to help. Please post the following:
Kind regards,
Bill
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the additional information, and please review the article again as it does not match your scenario.
What that article does is:
GIVEN there are Epics with child issues (e.g., Story, Task, or Bug)
WHEN a schedule occurs (e.g., once per week)
THEN for each Epic, update the Epic's Start Date to the minimum value for the child issues' Start Date
AND update the Epic's Due Date to the maximum value for the child issues' Due Date
Instead, you want to:
And so the branch JQL from that article will not work for your scenario as it gathers all the Epics, and then updates all of them.
Some other problems with the rule image you posted are:
It is possible to solve your scenario with a single rule by limiting it to specific issue types and allowing the rule to trigger itself (by detecting field changes). For example:
In the rule details at the top, enable this option:
Check to allow other rule actions to trigger this rule. Only enable this if you need this rule to execute in response to another rule.
With that option, the rule can detect if a Subtask's fields are changed, and then update its parent Story (or Task or Bug). After that update happens, the rule will trigger again and update the Epic.
Earlier I noted edge cases for this scenario. The above rule will make updates when the fields change in the child issues (at both levels). It will not handle these edge cases (as the rule will not trigger / handle them):
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
thanks @Bill Sheboy it appears this works, just need to sort smart values as you mentioned. The error I kept getting was having multiple Start Dates for some reason. Thanks again!
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @wiwan
I don't know what went wrong with given link but I listed what I'd do for your case:
- add a trigger "Field value changed" and select the fields: Start date and Due date
- add an action: Branch and Choose "Parent"
- add an action to update the parent task's dates:
-- Start date: the smart value to find the earliest start date of all child tasks
{{issue.subtasks.startDate.min}}
-- Due date: the smart value to find the latest end date of all child tasks
{{issue.subtasks.dueDate.max}}
I hope this helps
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.