You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
Next: Root
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
Team,
I am having a text drop down option with all team names, my automation should copy that value and set as a value in Teams custom field (which was originated from advanced road maps) but it is throwing errors.
Added all the screen shots.
Thanks in advance.
Hello @Raju Mandapaka
There are two things to address in your rule.
1. The use of asJsonString
As per the documentation here:
https://support.atlassian.com/cloud-automation/docs/jira-smart-values-json-functions/
...if "JA Team 2" is a selection list then you need to use
issue."JA Team 2".value.asJsonString
2. Setting the Team field in the issue.
When setting the Team field you need to use the ID associated with the Team, not the Team Name, as noted in this article:
So, you cannot directly take the text that represents a Team Name from another field and assign that value to the Team field.
I have not yet found information on how you could take the text name and look up the ID for the team through an automation rule.
I was able to do this using the answer from another post: https://community.atlassian.com/t5/Jira-questions/Custom-Field-Copy-when-Splitting-Ticket-Automation-not-working/qaq-p/2258148
{
"fields": {
"customfield_10100" : "{{triggerIssue.fields.customfield_10100.id}}"
}
}
You'll need to update the ID (in the example above, it's 10100) to the ID if the Team field in your instance. You can find this by going to Issues > Custom Fields > click the ellipsis next to the Team field > click "View field information" > and copy the ID at the end of the URL of the page it opens. That's your Team field ID.
It's dynamic: whatever the value of the trigger issue's Team field is will then copy to the destination issue.
If you want it to set the destination issue's Team field to a static value, then you can replace the smart value with the Team field's value ID. Example -- 485 in the code block below:
{
"fields": {
"customfield_10100" : "485"
}
}
If you're not sure what your Team's value ID is, then in the main navigation menu along the top of the page, select Filters > View all issues > "Switch to JQL" (if it's not already set to that) > and in the query bar, type:
"Team[Team]" =
and wait a moment for the list of teams to pop up in a dropdown menu. You may need to backspace then hit the space bar again for it to aggregate the Teams list. Start typing your team name and select it when it pops up. It will then convert the team name to the ID. You can then copy that to your automation rule to replace the 485 number I used in the example above (be sure to keep the quotations).
Final setup of automation rule example:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There is a duplicate of this post here:
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.