I need to sum the story points in a list of issues on the send email action within automation for jira. Some of the issues will have 0 story points and some will have many.
I have tried {{issues.size}} and {{issues.story points.size}} but they get the number of issues and number of issues with non 0 story points rather than adding the number of story points.
Found my own answer, for those in the future:
{{#=}}{{issues.Story Points.join(" + ")}}{{/}}
The {{issues.Story Points.join(" + ")}} gets all of the story points and puts them in an equation like this: 1.0 + 1.0 + 1.0 + 2.0 + 2.0 + 3.0 + 1.0 + 3.0
Then the {{#=}} ....... {{/}} does the math on that equation to print out 14 in the end.
Thanks internet!
Hey @ccaprio Are you able to share your automation for Jira setup where you used this logic? I have a similar use-case and I'm having trouble applying your answer in my project. Thx
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I actually dont have access to that JIRA anymore but it ran a branch using jql to get a list of issues and then had this logic in the action tag after it. You also had to make sure the checkbox for handle all issues at once or something similar to that in the branch section is checked. Hope you figure out your problem!
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.