Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,368,113
Community Members
 
Community Events
168
Community Groups

Create a Percent Complete Off of Children Issues

I have seen different ScriptRunner scrips doing similar functions but unable to put all of the pieces together on this. I need to create a script that calculates the % of all "DONE" related issues that have a  "Child of" relationship to the parent issue. Any help would be greatly appreciated.

1 answer

1 accepted

0 votes
Answer accepted

I ended up using the "Calculated Number Field (by JWT) to complete this request. 

 

Sample expression:

(
(
count(filterByIssueType(filterByStatus(linkedIssues("parent of"), "approve,done"), "Audit")) +
count(filterByIssueType(filterByStatus(linkedIssues("parent of"), "to be released,production validation, done"), "Development, Export File Development")) +
count(filterByIssueType(filterByStatus(linkedIssues("parent of"), "done"), "Meeting, Requirements, Task, Sub-Task,Training"))
)
/
count(linkedIssues("parent of"))
)
*100

Hello, 

Where do you use this formula in Jira? Thanks

@Justine Comtat I ended up leveraging a Calculated Number Field post function that comes with the Jira Workflow Toolbox add on. I put that on an any status to any status transition in the workflow that I can execute from different workflows based on their transitions being executed. 

Suggest an answer

Log in or Sign up to answer
TAGS

Atlassian Community Events