I have:
- Parent issue with custom filed 'Team Sum'
- Sub-Tasks with custom field 'Team'
Goal:
I want to summarize the values of the field 'Team' in the custom field 'Team Sum'
Additionally:
The custom field 'Team' is a multiple option to choose type.
The field 'Team' values are: 'Front' 'Back' 'QA' etc...
Example:
If the Parent has two sub-tasks like:
-Sub-task 1, has the option 'Front' in the field 'Team'
-Sub-task 2, have the option 'Back' in the field 'Team'
-Custom field 'Team Sum' in the Parent issue has options 'Front' & 'Back'
Also:
I know how to summarize the story points, and I tried to do the same with the field team, but it didn't work, here is how I did it:
Hi Casper,
I'm Luka from codefortynine and I think your use case is an interesting use case for our app Dynamic Custom Fields for Jira.
If you want to avoid the limitations of Jira Automations, you could try to add this Jira expression as a Dynamic Custom Field (You need to replace the custom field ID with the corresponding custom field ID of your instance. You can read more on how to find your custom field ID here):
issue.subtasks?.flatMap(s => s.customfield_10145 != null ? s.customfield_10145 : null).flatMap(f => f != null ? f.value : null).sort()
I have to admit, the expression will not filter out duplicate teams, but that might be possible with some Jira expression magic beyond my comprehension.
Let me know if this would work for you.
Hi @Casper,
Is Team Sum a text field? If so, try to add this to the action Edit issue:
{{issue.subtasks.Team.value.flatten().distinct().join(" & ")}}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Kseniia Trushnikova ,
Yes, is a text field.
I created a Field 'Team Sum' as a:
- Text field ( Read-Only )
- Select List ( Multiple Choices )
Try to use your solution, and it doesn't work.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Casper, there’s the field Teams instead of Team Sum on your screenshot. Are these fields the same?
Can you please share the rule logs?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Casper, everything looks right… The parent issue has been edited.
Can you share the new value of Teams in DST-346?
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.
@Casper, for some reasons it works in my Jira. I've just tested it with a select List (multiple choices) and a text field (single line).
Please check are there any entries in the parent issue history?
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.
Did you catch the news at Team ‘25? With Loom, Confluence, Atlassian Intelligence, & even Jira 👀, you won’t have to worry about taking meeting notes again… unless you want to. Join us to explore the beta & discover a new way to boost meeting productivity.
Register today!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.