Community Announcements have moved! To stay up to date, please join the new Community Announcements group today. Learn more
×Hi there,
I'm trying to use automation to leave an internal comment that tags both the assignee and the task's approvers if the SLA is going to breach soon. I can't figure out the code to use though to have the comment tag the approvers if there are multiple approvers.
Right now this is what the comment looks like:
Hey [~accountId:{{assignee.accountId}}],
This ticket will breach its SLA in 2 hours. Please respond to the customer before our standard response time passes.
Approvers: [~accountId:{{approvers.accountId}}]
Cheers,
Your friendly automation bot
The approver's output is a link that ends in atlassian.net/people/5e725189d6e3cc0c3dda032f,%205f32e7d23aa35b003fd05e01, which is just both accountId's with a comma separating them.
Does anyone know the proper way to handle user picker fields with multiple users?
Thanks,
Michael
Hi @Michael Cole ,
welcome to the Atlassian Community!
Please try something like this:
{{#approvers}}[~accountId:{{accountId}}]{{^last}},{{/}}{{/}}
There is a great article about smart values and lists, I found the information there.
This worked perfectly! And thank you for the article. I wasn't sure where to look in the documentation since I'm not familiar with some of the Jira terms yet. I'll give this a thorough read-through.
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.