Calculate Custom Field on Issue Update
Overview
Currently, you cannot add a calculated custom field in Jira Cloud.
However, using the IssueUpdated
event, the sum of multiple fields can be calculated when an issue is updated.
Example
My project has three custom fields: Cost, Shipping Cost, and Total Cost. These fields are available for all issue types. When an issue or sub-task is created, I can define the values of the Cost and Shipping Cost fields, however, the Total Cost field is not automatically calculated as calculated custom fields are not available in Jira Cloud. Using this script I can trigger a calculation when the issue is updated, allowing me to sum the ...