Need Help with script - Update the Epic with the average from the linked tasks field

Catheline October 21, 2022

Hello All,

We are trying to write a script or scripted field to update an Epic field (say Progress average) with the average of the linked tasks/story's - field say Progress (select list with number values).

Does anyone have any advice on how to write this script or if there is any other way to do this? Can you please direct me to the appropriate links?

1 answer

0 votes
Ram Kumar Aravindakshan _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 23, 2022

Hi @Catheline

In your description, you mentioned:-

We are trying to write a script or scripted field to update an Epic field (say Progress average) with the average of the linked tasks/story's - field say Progress (select list with number values).

Could you please clarify which Epic field you are referring to? Is it the Epic Link or Epic Name or Epic Status or Issue Type?

If it is a System field, this it cannot be done.

However, if it is a custom field that is not locked by Jira, then it may be doable.

I am looking forward to your clarification.

Thank you and Kind regards,

Ram

Catheline October 23, 2022

Hi Ram - Sorry I did not explain it clearly.

The average should be updated in a custom field of Issuetype Epic.

Hope this clarifies , waiting for your update.

Thank You,

Catheline

Ram Kumar Aravindakshan _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
October 24, 2022

Hi @Catheline

In your last comment, you mentioned:-

The average should be updated in a custom field of Issuetype Epic.

I assume this is for the Custom Issue Picker scripted field. Please confirm.

If yes, you cannot directly add value to it.

Instead, you will need to add another Custom Scripted Field to do the calculation, and you can then specify that file into the Issue Picker's Fields to search configuration.

So the result will appear in both the Custom Scripted Field and the custom Issue Picker field.

I am looking forward to your clarification.

Thank you and Kind regards.

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events