I am fairly new to JIRA and have inherited a system with some scripted fields. The script looks at an Epic , finds the Tasks associated, then the Sub-tasks then sums the effort progress from each Sub-task to come up with the current progress in the Epic. The same script run from a Task does similar but comes up with the current progress in the Task. This is all fine. However, what we would like to do, is have this field in the Epic and the Task, update whenever the Sub-task is updated so that whenever a dashboard summary of Epics is produced the scripted field for the Epic is correct without having to open each Epic. So the question is, can a script run from opening a sub-task, update the same script field in an unopened Task or Epic? Any guidance welcome.
Sorry for the late response but this is a side task and other stuff had priority!
I am using the embedded script console in JIRA.
I have since managed to amend the Epic by finding the Task from the sub-task ( using GetParentObject ) and then the Epic using some code I found:
def customFieldManager = ComponentAccessor.getCustomFieldManager();
def epicLink = customFieldManager.getCustomFieldObjectByName('Epic Link');
then I run the original Epic code with the found parent and that seems to work.
Ideally I would like to update the Sub-task, Task and Epic fields all at once but that I guess I would need to return 3 values. Is that allowed?
We’re proud to announce that our integration with Amazon DevOps Guru is now live. The Amazon and Opsgenie product teams have worked together to build a deep integration between Opsgenie and the new...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events