Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Set up the automation to fill in the Asset Object field with the reporter object

Vadym Bezkorovainyi March 26, 2025

Hey There!

I'm trying to set the automation for my tickets. The simple one is to see who is reports the request via Portal, find this user in the Jira Assets and fill the custom field(assets objects type) with a object of this user from Assets. From the screenshot below i want automatically get the "Employee Full Name" filled with an object from Assets.

Screenshot 2025-03-26 at 12.36.59.png

This is what i have done already so far and looks like automation works, but the field is not filled with an object :(

Screenshot 2025-03-26 at 12.42.43.pngScreenshot 2025-03-26 at 12.43.07.pngScreenshot 2025-03-26 at 12.43.33.pngScreenshot 2025-03-26 at 12.43.50.png

As you can see - it gets the data and can put the info in the Comments, but not fill the field. Any ideas why?

Thank you!


3 answers

1 accepted

5 votes
Answer accepted
Kim Euker
Community Champion
March 26, 2025

Since Employee Full Name is an asset field, all you need to do is to use the query you are using in the lookupObjects for your edit.  If you remove your text from the Employee Full Name field, you should see that it is looking for a query.  

Put this into your Employee Full Name on Edit.
ObjectType = "Employees" and "Atlassian Account ID" = {{issue.reporter}}

Kim Euker
Community Champion
March 26, 2025

Sure.  Here is an example:

2025-03-26_09-37-00.png

When you have an asset field, it shows you that it is specifically looking for an AQL query, as shown in the example.

Replace that greyed text with your query:
ObjectType = "Employees" and "Atlassian Account ID" = {{issue.reporter}}

 Vadym Bezkorovainyi likes this
Kim Euker
Community Champion
March 26, 2025

@Vadym Bezkorovainyi   I reposted as my own answer to your question :-)

Like Vadym Bezkorovainyi likes this
2 votes
Marc - Devoteam
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.
March 26, 2025

Hi @Vadym Bezkorovainyi 

Welcome to the community.

I see the field "Employee Full Name", is an asset field right or not?

If it's an assets field, what is the context of this field.

{{lookupObjects.name}} what will this give as result.

 

 

Vadym Bezkorovainyi March 26, 2025

Hey @Marc - Devoteam 
Yes, it is asset field. Here is a context
Screenshot 2025-03-26 at 13.32.41.png

{{lookupObjects.name}} - on the last screenshot there is a Comments for a tickets - it gives the name of attribute from Asset ObjectType

Kim Euker
Community Champion
March 26, 2025

Since Employee Full Name is an asset field, all you need to do is to use the query you are using in the lookupObjects for your edit.  If you remove your text from the Employee Full Name field, you should see that it is looking for a query.  

Put this into your Employee Full Name on Edit.
ObjectType = "Employees" and "Atlassian Account ID" = {{issue.reporter}}

Like # people like this
Vadym Bezkorovainyi March 26, 2025

Hey @Kim Euker
Thank you for the feedback!
If you can, please provide more info on what to do because I'm nooby with JSM :)

Kim Euker
Community Champion
March 26, 2025

Sure.  Here is an example:

2025-03-26_09-37-00.png

When you have an asset field, it shows you that it is specifically looking for an AQL query, as shown in the example.

Replace that greyed text with your query:
ObjectType = "Employees" and "Atlassian Account ID" = {{issue.reporter}}

Like Vadym Bezkorovainyi likes this
Vadym Bezkorovainyi March 26, 2025

@Kim Euker, let me try

Vadym Bezkorovainyi March 26, 2025

@Kim Eukeryou are my hero!
Thank you! IT WORKS NOW!

Like Kim Euker likes this
Kim Euker
Community Champion
March 26, 2025

@Vadym Bezkorovainyi   Please be sure to Accept my answer.  I'm glad it worked for you

1 vote
Tomislav Tobijas
Community Champion
March 26, 2025

Hi @Vadym Bezkorovainyi ,

What's {{lookupObjects.get(0)}} returning? Is it object name/label or is it object key? If you could extract only the object key and store it in the field, I believe it will work. (we did something similar before)
Maybe try using {{lookupObjects.get(0).key}} and storing it in the field.

Can you also take a screenshot of this comment part/action and which smart values are you using there?

Cheers,
Tobi

Vadym Bezkorovainyi March 26, 2025

Hey @Tomislav Tobijas 

I have tried  {{lookupObjects.get(0).key}} but still the same - not filled field there :(Screenshot 2025-03-26 at 13.36.17.pngScreenshot 2025-03-26 at 13.37.05.png

Also adding the Audit Logs

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events