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

Set Assignee field with custom field value that is the assignee.displayname

deborah a plante September 6, 2024

Data Center Jira/JSM 9.13/5.13

Issue contains a Asset custom field to pull in Company asset and its attributes.  One of those attributes is "contact name". 

Have a placeholder text custom field for the "contact name"

The "contact name" = the jira users "display name".

I have it working if I enter the jira username, but that is not something that is captured in the Asset objecttype import.  

 

I have Scriptrunner and Automation available.   Any advice or guidance would be greatly appreciated

 

 

1 answer

0 votes
Vijay Dadi
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 9, 2024

Hello @deborah a plante ,

If you want it capture the data using object import, you have to do a user lookup using a email address and then u set the account id to the attribute Contact Name. This will work as I have it configured for one of my customers. Please do let me know if you need more details on the same.

Regards,

Vijay

deborah a plante September 10, 2024

Hi Vijay,   if you could share the details of your automation, I would greatly appreciate it

Vijay Dadi
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 10, 2024

Hello @deborah a plante ,

 

Here is the snippet of the automation.

atl account.png

{{webResponse.body}} - this smart value will give you details of the user's Atlassian account.

 

When I browse for my user account in jira, using the URL 

https://vijay2am.atlassian.net/rest/api/3/user/search?query=vijay.hd@gmail.com

The result I get is shown below. Hope this helps.

[
{
"self": "https://vijay2am.atlassian.net/rest/api/3/user?accountId=712020:ffb8ec7e-779f-4665-a854-c4b02fe14463",
"accountId": "712020:ffb8ec7e-779f-4665-a854-c4b02fe14463",
"accountType": "atlassian",
"emailAddress": "vijay.hd@gmail.com",
"avatarUrls": {
"48x48": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/712020:ffb8ec7e-779f-4665-a854-c4b02fe14463/3f6d690c-edc6-4e04-b383-714f3765dc35/48",
"24x24": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/712020:ffb8ec7e-779f-4665-a854-c4b02fe14463/3f6d690c-edc6-4e04-b383-714f3765dc35/24",
"16x16": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/712020:ffb8ec7e-779f-4665-a854-c4b02fe14463/3f6d690c-edc6-4e04-b383-714f3765dc35/16",
"32x32": "https://avatar-management--avatars.us-west-2.prod.public.atl-paas.net/712020:ffb8ec7e-779f-4665-a854-c4b02fe14463/3f6d690c-edc6-4e04-b383-714f3765dc35/32"
},
"displayName": "Vijay Dadi",
"active": true,
"timeZone": "Asia/Calcutta",
"locale": "en_US"
}
]

 

Vijay

 

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
TAGS
AUG Leaders

Atlassian Community Events