I have a group of linked stories under an epic that have start and due dates. If I need to push out a due date I want the rest of the stories to automatically update their start and end dates to conform with that change and adjust by the same amount.
I am not sure how to build an automation like this and need some help.
Hello @Joe Mraz
When you say the issues are linked do you mean that they are linked to each other? What link type(s) are you using? How are you indicating that the Start Date of Issue X is dependent on the Due Date of Issue Y?
How many such issues exist in your longest "chain" of such relationships?
Hello Trudy. Basically, the stories are a phased approach in this case. So story 1 is linked (blocks) to story 2. Story 1 needs to be completed to work on story 2. If story 1 needs to be extended, then I want story 2 to be pushed out but keep their current amount of time for story 2 but push it out. Then it would push out story 3, 4, etc, so that we make one update to a story timeline and the rest updates properly.
This chain is currently 10 stories.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I have provided an example of how to do that with an Automation rule in my answer on this post:
Note that this rule needs to call itself recursively to go through the chain of linked issues. There is a limit of 10 such calls so if you have more than 10 issues in the chain following the first one you update, then the rule will update only the first 10. And you have to check the box on the Rule Details page to "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."
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Getting some errors when from the audit log:
Failed to get value for (issue.startdate.plusDays(duration.asNumber)): {{issue.startdate.plusDays(duration.asNumber))}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Where I used "startdate" or "Start date" or "duedate" or "Due date" or any variations thereof, you need to be using the names of your fields that you are using to indicate the beginning date and the ending date.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I got it working now. However, for the next story in line it only changes the start date correctly. The due date says "NO DUE DATE" which then erases the ones after the second story and so on. Getting closer. Any thoughts?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please show us the rule(s) you have created and the details of each step, plus the details from the audit log for execution of the rule(s).
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
At this moment I'm not able to see/access any of the attachments you added to your post.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Joe Mraz -- Welcome to the Atlassian Community!
In your rule's create variable action for "duration" you use this smart value expression:
{{issue.dueDate.plusBusinessDays(diff))}}
That is not valid as "diff" has no meaning / value there.
Were you trying to use the change in value for the Due Date of the trigger issue? If so, that would need to be calculated from the changelog after the trigger and saved for later use in the branch.
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.
(I don't know why I can't see the images from OP's most recent replies. I've tried three different browsers and an Incognito window.)
Adding context: OP is using an example from one of my previous answers as the basis for the rule.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks, Trudy!
The definition of the duration variable and increment of the date seem comingled / different from your linked solution. If they are separated again it should work, with the key being how much to increment:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Bill Sheboy Hi Bill. That did not change anything when I updated it.
@Trudy Claspill Hi Trudy, is there a way I can attach the files so you can see?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Did you upload image files in those posts? What type of files did you upload?
If Bill can see them then the problem may be on my side.
The links I see for your images look like this:
In comparison the links I see for the images I attached in the referenced post look like this:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Trudy Claspill I did not upload. I just cut and paste the pictures. Is there a way to upload .jpeg files?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Save a copy of the file on your local system then use the Insert Photos option to insert/attach the jpeg to the post.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Bill Sheboy 's comment about your Create Variable action to calculate "duration" is wrong. Compare yours to mine from the reference post.
I used {{issue.Start Date Field Name.diff.(issue.Due date field name).days}}
I would amend that now to use the abs function also.
{{issue.Start Date Field Name.diff.(issue.Due date field name).days.abs}}
You used:
{{issue.dueDate.plusBusinessDays(diff)}}
That is an entirely different calculation to add a number of business days to the Due Date, with that number of days being specified by diff
Because of that problem your editing of the Due Date field in the Edit action will not be correct.
In addition, you may want to double check that the linked issue actually has a Due date value and a Start date value before you calculate duration and edit the issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Still not working. I cannot set the Due Date. My logs show how many days that need to be added but it keeps saying NO DUE DATE. Very frustrating. Here is everything again because I made a lot of changes. All my logs show data.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The use of field names in smart values can be space and case sensitive. Make sure that the field names you are using in the smart values match the field names you see in the UI for the actual issues.
I see a lot of placing where you are changing case, such as
TriggerIssue vs. triggerIssue vs. triggerissue (with a lower case "i" in the last one for "issue"
So I also recommend that you make sure the case on all those references is correct.
triggerIssue - lower case "t" and upper case "I" for "Issue".
When referencing the current issue in focus use {{issue.... with a lower case "i".
I also notice that you are trying to reset Due date based on Start date in the target issue.
Two things I would recommend with regard to this:
1. Don't use the focused issue's Start date as the basis for assigning a value to this field. At this point in time, the start date of the issue has not yet been changed so it is using the original Start date in the calculation. Instead use a reference to the trigger issue's due date, like you do when setting Start date.
{{triggerIssue.duedate.plusDays(numberofdays)}}
2. Print that value into the Audit Log to confirm it is calculating correctly.
3. Also, I see that you are actually pushing the new Start date out by an additional day, so you need to factor that in to the numberOfDays calculation:
{{issue.Start date.diff(issue.duedate.plusDays(1)).days.abs}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Spend the day sharpening your skills in Atlassian Cloud Organization Admin or Jira Administration, then take the exam onsite. Already ready? Take one - or more - of 12 different certification exams while you’re in Anaheim at Team' 25.
Learn more
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.