Insight Read Only field scope help - trying to display 2nd attribute which is another object

Jacob Jaskolka April 7, 2022

I have looked at every single insight post and have tried a hundred (literally) combinations of scopes and can't get a read-only field to display any data.

I have an Insight object field in Jira where users select the application, based on application name. I am looking to use a read-only field to display the Team Managing (which is another object) and cannot figure out the IQL for the filter scope or the filter assign scope.

Any help would greatly be appreciated.

Here is the setup

Screenshot 2022-04-07 111555.png

User picks Applicaiton Name in Jira which pulls from this object list.

 

Team Granting Access/Managing is pulled from another object, IT Teams:

Screenshot 2022-04-07 111740.png

My read-only field I want to display the IT Team linked under Team Managing.

 

Thank you

1 answer

1 accepted

0 votes
Answer accepted
Jorden Van Bogaert
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 9, 2022

Hi @Jacob Jaskolka 

Your use case may be simpler by just adding the "Team Managing" attribute on the issue view.

Use case with 1 custom field:

On the custom field to select the "Managed Applications", click "Edit Insight Configuration". Locate the "Object attributes on Issue view" setting and add the "Team Managing" attribute.

Your result will be that the Insight object will simply display the value for Team Managing in the same field instead of needing an additional field to store the Managing Team.

 

Use case with 2 custom fields:

On the "read-only" field, configure the following:

  • Object schema:
    • <Your object schema name>
  • Filter Scope
    • objectType = "IT Teams"
  • Filter Assign Scope:
    • key IN (${customfield_XXXXX${0}})
    • Replace "XXXXX" with the ID of the "Managed Applications" field.

Let me know how it goes

Kind regards
Jorden

Jacob Jaskolka April 9, 2022

Hello @Jorden Van Bogaert

Thank you for your well thought out and thorough response. 

Regarding use case 1 I have that in place already, but it isn't too helpful as the API and automation for Jira cannot read added attributes to a field. I'm attempting to do some auto assignment of an issue based on the application chosen. From the screenshot above - If Aha is chosen the ticket would get routed to Application Services team, and so on. This is why I am trying to use a read-only field.

Use case 2 custom fields:

Thank you very much for the pointers in the right direction. It seems to make sense to me as to how it should pull the data. I put it into the field config, created a couple test tickets, updated tickets and still nothing shows.

I am unsure as to what the ${customfield_14083${0}} pulls  - should it return all the attributes of the application, or does it just return the key and application name from the Managed Application field? The Managed Application key is not in the IT Teams object at all so maybe that is why it returns nothing?

Should I be pulling specifically the customfield_14083(Managed Application) attribute I need somehow? 

Anyway.. I'm still stuck and going to add a couple more screenshots to hopefully clarify.

This is my field config

5084620282483812832_121.jpg

 Here are the two objects and their attributes:

5084620282483812834_121.jpg5084620282483812833_121.jpg

Jorden Van Bogaert
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 10, 2022

Hi @Jacob Jaskolka 

Not sure why the original query is not returning the correct value. ${0} is simply returning all values of the referenced field, you can read more about it in this article.

However, I've played around with it myself a little bit and have found a query that should return the required result:

object HAVING inboundReferences("Key" IN (${customfield_14083${0}}))

 Simply copy paste the above in the "Filter Assign Scope" of the read-only field and you should be seeing the value pop up after editing existing tickets or after creating new tickets.

FYI, the query is just a search that returns all IT Teams that have an inbound reference coming from any object selected in the Managed Applications field.

Make sure you put the read-only field on the view screen to see its value :)

Hope this resolves it!
Kind regards
Jorden

Jacob Jaskolka April 12, 2022

This worked wonderfully!! Thank you so very much for all the help!

Thank you for the article link as well to help explain how the values are returned.

Now that I have a working example I can play and learn more.

Like Jorden Van Bogaert likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events