Hi,
I’ve been trying to create a custom field that sums all field values for all issues in an epic if a value of another field is equal to a specific value.
I’ve been able to accomplish the sum, however I can’t get the condition to work.
My exact case:
sum all “Days Off” for all issues in an epic if “Day Off Type” = “Annual Leave"; “Holiday on Demand".
What I got so far:
issue.stories.sum {it.get("Days Off")}
I am not sure where to add the if and how to go through all of the stories of the epic.
Hi @Krzysztof Kiser ,
try this:
issue.stories.findAll {it.getAsString("Day Off Type") in ["Annual Leave", "Holiday on Demand"]}.sum {it.get("Days Off")}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.