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

Display Insight object custom field as smart values

Greg
Contributor
December 9, 2021 edited

I am using Automation to send emails which include specific fields from customer Requests. When attempting to add the Insight custom field, the only value returned is the Insight Key. I would like it to display the Insight name instead.

I have found other users with similar questions here and here, however their issue was that both the Key and the Name were displaying and they wished to correct that to only the Name.

My smart value code looks like this:

*Manager:* {{issue.customfield_10186}}

And the email comes across like this:

   Manager: IT-19666

I have attempted to add the .summary, however that returns only a blank field.

Any ideas on how I may get the Insight name to appear?

3 answers

3 votes
Mikael Sandberg
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
December 9, 2021

Have you tried using the lookup object to get the attributes for the object? I am using it to get a list of approvers when someone submits an access request for some of our tools. The automation I am using looks like this:

Screen Shot 2021-12-09 at 2.49.09 PM.png

Greg
Contributor
December 11, 2021

Hi Mikael,

Thanks for the idea. Unfortunately that option doesn't work for my instance. Below you can see what my automation is accomplishing. I am using the smart values to add the details of the HR project request to the Description field of a new task in the IT project.

 

hrAutomation.png

 

And here is the new Task as it appears. Note that only the Insight object key is being shown, and not the Name:

 

issueCreated.png

Based on the Jira documentation, I should be able to display both the Key and the Name:

insightSmart.png

Kalin U
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.
April 14, 2022 edited

Update: please see my suggested answer. I misplaced it as a thread response rather than an independent answer.

1 vote
Kalin U
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.
April 14, 2022 edited

Hey, @Greg 

If you change the following excerpt from the Description field, you should get the result you expect.

*Manager*: {{issue.customfield_10186.Name}}

I assume you have an attribute "Name" for the object type "Manager" in Insight. If you have two attributes, say "Name" and "Surname", then you should modify the smart values in Description as follows:

*Manager*: {{issue.customfield_10186.Name}} {{issue.customfield_10186.Surname}}

Please let us know how you handled your case. Your original post is from late 2021.

Regards,
Kalin

Greg
Contributor
April 14, 2022

Hi @Kalin U ,

Thanks for the follow up.

I was able to get the field to display by formatting it as follows:

*Manager:* {{"Employee Manager".Name}

 ("Employee Manager" is the Insight Custom Field name in my instance)

I'm not sure anymore how I landed on this solution, but it has been working.

Thanks again,
Greg

Kalin U
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.
April 15, 2022

Thanks for sharing your solution. The customfield_xxx format would work if it was referenced through {{lookupObjects}}. Your suggestion is perfect.

Regards,
Kalin

0 votes
Greg
Contributor
April 14, 2022 edited

.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
atlassian, ace, atlassian community event, donation, girls who code, women in tech, malala fund, plan international, kudos, community badge, badge, atlassian badge, International Women’s month, International Women’s Day, women's month, women's day

10 for Change at Atlassian Community Events

Show up and give back by attending an Atlassian Community Event: we’ll donate $10 for every event attendee in March!

Join an Atlassian Community Event!
AUG Leaders

Upcoming Jira Service Management Events