Hi Team,
I have a requirement to count the no.of "Connection" subtasks and display them on the custom field. We have two subtask, one is a "Sub-task" and another is "Connection". The main parent ticket will have both Sub-task and Connection subtasks, but want to display the only "Connection" tickets, the following scripts is displaying all subtasks. is there any correction to update the only "Connection" subtasks in that custom field "Connection Count" ?
Scripted Field : Connection Count
def subTaskSum = 0
issue.getSubTaskObjects()?.each {
subtask -> subtask.getResolution()==null?subTaskSum += 1:subTaskSum
}
return subTaskSum