I'm looking at how I can create an automation that calculates SP based upon the task complexity field (easy, medium, hard) and the time tracking field native to Jira. Task complexity is a custom field (10347) and it time tracking is in hours.
Still pretty new to this, but basically what I started off with was this:
{{#=}} {{#if(issue.customfield_10347.equals("Easy"))}} {{issue.timeTracking.timeSpent / 8}} {{/}} {{#if(issue.customfield_10347.equals("Medium"))}} {{issue.timeTracking.timeSpent / 8 * 2}} {{/}} {{#if(issue.customfield_10347.equals("Hard"))}} {{issue.timeTracking.timeSpent / 8 * 3}} {{/}} 0 {{/}} What I believe is happening is that the custom field is more or less failing and then i default into 0 SP.