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.
Hi there,
What tool are you using for scripted fields? It may be possible.
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?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.