Forums

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

Need to print earliest planned dates among all subtasks on story level

C S Seshagiri November 15, 2023

Screenshot 2023-11-15 210928.pngWhen user story is moved to “ Ready for Build” - Trigger looks at the planned start dates of all subtasks and takes the earliest of them and populates the “Planned Start Date” on the user story. Takes the last of them and populates the planned end date field on the user story. After this happens, lock these two fields from any overrides except by admin users. When automation runs, it shows no action performed.

Any suggestions or details with screenshot would be appreciated.

Thanks in advance

 

2 answers

1 accepted

1 vote
Answer accepted
Trudy Claspill
Community Champion
November 15, 2023

Hello @C S Seshagiri 

The For Parent branch is trying to look at the parent of the issue that triggered the rule, which is the Story issue. If the Story has no parent issue, then the rule stops running.

Based on your description of what you want, using the For Parent branch is not the correct action.

If you want to look at the dates on the Story's subtasks, get the earliest date from them, and then put that into a field in the Story your rule needs to look like this instead. In my example I'm using the Start date field

Screenshot 2023-11-15 at 9.31.06 AM.png

After confirming that the trigger issue is a Story, then add a step to confirm that the trigger issue has subtasks.

Then add a step to get a list of all the subtasks for the trigger issue, where the date field is not empty.

Then check that you got some results in that list.

Then set the date field to the earliest data from the issues in the list.

Screenshot 2023-11-15 at 9.33.26 AM.png

C S Seshagiri November 16, 2023

Thank you @Trudy Claspill . It worked as per request. Much appreciated!!

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
November 15, 2023

Hi @C S Seshagiri 

Please post an image of the audit log details, showing the rule execution.  That may help explain what you are observing.

And as your explanation of the rule includes more details, I suggest posting an image of the entire rule, in one image.  That can be done with a screen capture or browser addon capable of scrolling page capture.

Until we see that...

You note checking subtasks, but that does not appear to be what the Lookup Issues action's JQL is doing.  Instead it gathers all issues in the entire project which have a "Planned Start Date".  Regardless of the story, its parent epic, etc.  Is that what you wanted to do?

Next, I recommend using the min and max functions on that date field in the lookup results, rather than relying upon the JQL and using the first and last functions.

Kind regards,
Bill

C S Seshagiri November 16, 2023

Thank you @Bill Sheboy  for sharing your thoughts. @Trudy Claspill has shared me the solution.

Like Bill Sheboy likes this

Suggest an answer

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

Atlassian Community Events