I created a Jira rule that triggers when a customer date field gets changed.
Once triggered, I'm trying to edit another customer date field using the value of the changed field and adding 3 business days to it.
For that field to modify, I used smart values, I entered this in the Edit work item- field section:
{{triggerIssue.customfield_10126.toDate.plusDays(3).toBusinessDay()}}
...but the field doesn't update.
Any ideas? Should I be using triggerIssue?
Thanks
Hello @Matt Brescia
Welcome to the Atlassian community.
Please show us the entire rule and the details of each step. We need that information to help you debug the problem.
I also recommend that you use the Log action to print into the rule execution log each smart value you are trying to use, immediately before you use it; i.e.
{{triggerIssue.customfield_10126}}
{{triggerIssue.customfield_10126.toDate}}
{{triggerIssue.customfield_10126.toDate.plusDays(3)}}
{{triggerIssue.customfield_10126.toDate.plusDays(3).toBusinessDay()}}
If there is something wrong with the references, logging the values one step at a time will help reveal that.
What type of field is customfield_10126? If it is a Date or Date/Time field then you don't need the "toDate" function.
As per the documentation, you also don't need parentheses after toBusinessDay
And what type of field is the one you are attempting to set?
Please also show us the full details from the rule execution audit log from an instance when the rule has been triggered. Make sure to click all the ">" characters at the end of the log message to expand all the details.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.