Hello 👋
In a Jira automation, I would like to retrieve the start date of the sprint from the old value when it has changed. My string is « when value changed : Sprint »
I tried using:
{{changelog.fields.customfield_10020.from.0.startDate.jiraDateTime}}
{{fieldChange.fromstartDate.jiraDateTime}}
But neither of them works.
➡️ How can I do ?
The Field Value Changed trigger on the Sprint field detects changes to any Sprints associated to the work item. It does not detect changes to the Sprint's attributes: Name, Start Date, etc. as they are not stored with the issue; only the Sprint id is stored, and the other data is looked up when needed.
Information about changes to the Sprint's attributes are recorded in the site Audit Log, and those may be read using a REST API endpoint with the Send Web Request action. An alternative for triggering the rule is using a site webhook and the Incoming Webhook trigger.
Would you please explain what problem you are trying to solve? That is, "why do this?"
Knowing that may help the community identify other solution approaches.
Kind regards,
Bill
I would like to know the sprint start date of triggered issue to compare with the current datetime and to know if a story has been removed or added in the current sprint.
So, I can retrieve the {{issue.sprint.startDate.jiraDateTime}} when the field is not empty.
But in case of, a story is removed of the current sprint to be put in the backlog, the sprint becomes empty, so I need to retrieve the previous value.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for that information, @Sébastien OZANNE
When the sprint changes for the work item, the Field Value Changed trigger can be used. And, the {{changelog}} smart value may be used to find previous values:
To get the removed sprint's Start Date by its id value, you would need to use the REST API.
Or, if you know there is at least one other work item still in the current sprint, the Lookup Work Items action could be used with JQL to find an example work item, and then get the start date from there.
project = yourProject AND sprint IN openSprints()
{{#lookupIssues.first.sprint}}{{#if(equals(state, "active"))}}{{startDate}}{{/}}{{/}}
Or, if you assume the current, active sprint has the latest date, please use:
{{lookupIssues.first.sprint.startDate.max}}
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.
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.