Hi,
I am trying to add an event listener so when any story or subtask is updated then its linked Epic will be updated with the sum of all the story points for its related issues.
I am using JIRA Cloud & Adaptavist script runner, I couldn't find anything on documentation as they always rely on parents.
The following examples and answers here, do not execute as I get error for the imports :
Would anyone be able to help or direct me to the right answer please ?
Thank you
Hi Mohamed,
Thank you for your question.
I can confirm that the reason that the code you have linked to in the articles above will not work inside of ScriptRunner for Jira Cloud is due to the fact the code you have provided is fro ScriptRunner for Jira Server and this will not work as Atlassian only provide a rest API in Jira Cloud and do not provide a Java API in the cloud like they do in Jira Server.
You can see more detailed information on the differences between the cloud and server versions inside of our documentation page located here.
I can confirm however that we have some example Script Listeners in the cloud documentation located here which you can refer to in order to see an example of how, to sum up, all of the story points for subtasks and to store the total on the parent issue.
You will be able to take this example script and to modify it in order to achieve your requirement.
If this response has answered your question can you please mark it as accepted so that other users can see it is correct when searching for similar answers.
Regards,
Kristian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.