Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Automation - copying smart value to components

Aman September 12, 2021

Hi All,

I am building an automation that copies the value of Affected Services to the components field whenever the value of Affected Services is updated. I already have all affected services listed as components.

Using the affected services smart value: {{issue.affectedServices.name}} I am able to successfully copy value of the affected service, only if there is just ONE affected service listed. As soon as I add a second or list two at the same time, nothing gets copied and component is blank. On checking the audit logs, the rule still shows as a SUCCESS.

I have attached screenshot of the rule for reference. I appreciate any help.Screen Shot 2021-09-13 at 10.26.07 am.png

1 answer

0 votes
Mohamed Adel
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 12, 2021

Hi @Aman 

 

If you have multiple value , I recommend to use the following : 

- Create advanced branching 

Screen Shot 1443-02-06 at 4.30.37 AM.png

- edit issue using the created smart value 

Screen Shot 1443-02-06 at 4.30.30 AM.png

 

Aman September 12, 2021

Hi @Mohamed Adel 

 

Thanks for your reply. I am getting the following error when trying to publish this rule.

Screen Shot 2021-09-13 at 11.47.37 am.png

Regards,

Aman

Mohamed Adel
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 12, 2021

Sorry I wrote it by mistake try that one please 

{{issue.affectedServices.name}}

Aman September 12, 2021

Hey,

I tried this earlier and again now, it only copies one value and not the rest.

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
September 13, 2021 edited

Hi @Aman and @Mohamed Adel 

What is the type of that field?  I wonder if splitting the values into a list that the advanced branch can use will help:

{{#issue.affectedServices}}{{name}}{{/}}

And...how are you updating the components?

Kind regards,
Bill

Like • Mohamed Adel likes this
Aman October 6, 2021

Hi @Bill Sheboy 

I am trying the JSON approach, but somehow not able to get it right. Not an expert on JSON, unfortunately. 

Would you be able to please help me with the JSON?

Kind Regards,

Aman

Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
October 7, 2021

Would you please post what you have thus far? That may provide some context to make adjustments.

And, if you are seeing errors in the audit log, please post those also.  Thanks!

Suggest an answer

Log in or Sign up to answer
TAGS
atlassian, team '25, conference, certifications, bootcamps, training experience, anaheim ca,

Want to make the most of Team ‘25?

Spend the day sharpening your skills in Atlassian Cloud Organization Admin or Jira Administration, then take the exam onsite. Already ready? Take one - or more - of 12 different certification exams while you’re in Anaheim at Team' 25.

Learn more
AUG Leaders

Upcoming Jira Events