Usage of placeholders in (Riada) Insight custom field

M Amine
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 13, 2018

Hi,

I'm trying to use a placeholder in 'Filter issue scope' in Insight Object/s custom field (CF) and I'm in trouble. 

Here is the use case: 

  • I have an object 'Application' having an attribute called 'Type'
  • The CF configuration that is working fine is the following: 
    • Filter Issue scope : Type = "Incident"
  • The CF configuration that is NOT working in Jira Service Desk (portal) : 
    • Filter Issue scope : Type = ${customfield_XXXXX}  
      I have created a hidden custom field that I populate with 'Incident'

My thought is that the hidden field is perhaps populated by Jira after the request creation that's why insight cannot find it. ?!?

My questions are:

  1. Are there any logs where the i can follow what insight is trying to do and what are the values of the placeholder?
  2. How can I solve my problem?

Thank you

4 answers

1 accepted

2 votes
Answer accepted
Nader Nassif
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 17, 2018

Hi Mohammed,

Can you try to convert the attribute that holds the value "Incident" & "Request" to objects instead ? Then it might be easier to achieve what you need.

The idea is to create an objectType called "Request type". Then create an object called Incident and another called Request. In your objectType "Application" change the type of the the attribute (let's call it Request_type as well) from default text into object and then reference the objectType you created "Request type". Then in your IQL filter you can use something like objectType HAVING inR(${Request_Type}).

If you have more questions feel free to share them anytime!

Cheers!

Nader

M Amine
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 17, 2018

Hi Youssef,

Thank you for your answer. It worked perfectly well (I changed your IQL: Used Filter Issue Scope (IQL) : Type = ${Request_Type} and added an Insight CF as hidden to the portal, so I can change its default value depending on the request type).  

But What I don't understand, is that, according to the documentation, placeholders must work with Jira custom fields also which is not the case here. Can you please explain why? what am I missing here?

thank you

PJ Wysota
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 17, 2018

They do work.

So if You would setup your field with:

Object Type mapping to apps, and Filter Issue Scope referenced either to Issue type or Customer Request Type (in JIRA SD) it would work. However You would need to keep attribute naming convention exactly the same as Issue Types or Customer Request Types. Any alteration (capital letters, special chars, etc.) between IQL in Filter Issue Scope, naming conventions used in non-Insight fields and values of attributes in Insight objects would break it.

What Youssef proposed is a good approach but misses actual reference to Issue Type/Customer Request Type itself (as is based on Insight objects only - which gives consistency of data). To have it related to e.g. Customer request types in JIRA SD I would setup hidden fields in CRTs on portal - to be auto populated with respective request type Insight object. Without JIRA SD I would use Workflow PF to populate it automatically based on Issue Type.

Or simply - mind the naming conventions and skip Request Types objects in Insight, mapping directly to CRT/IT if they are listed as attributes in App objects.

Like Amr Hamza likes this
1 vote
Claire Berry October 20, 2021

I had the same issue here and solved it by putting .label in the placeholder of my custom field. (My custom field was a single select list)

So for yours:
Type = ${customfieldName.label}  

I am aware this is a few years too late but might help someone else who comes across this thread like I did trying to solve it..

Karolina Dylewicz February 22, 2022

wow! @Claire Berry thanks a lot :) it did help! haha 

it's always worth posting an answer :) 

0 votes
M Amine
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 13, 2018

@Alexander Sundström can you please help?

 

thank you

0 votes
PJ Wysota
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, 2018

OK, I might know what is all about, but to not mislead You I would need some more details:

1. Hidden Field - what kind is it? Insight, or JIRA Field (Text, Select etc.)?
2. Do you have ObjectType in Insight called "Type" or "Incident"?
3. Have you tested variable with CF name instead of custom field_XXXXX?
4. Have You considered using Postfunction to populate it? cause auto populating values to Insight or JIRA fields based on Insight object attributes or Insight Field values do not work automatically on in-line editing

M Amine
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 13, 2018

Dear @PJ Wysota,

Thank you for your quick reply. Here are the needed info

  1. Jira custom field (text or select list, I can change it to Insight CF or other if needed)
  2. No
  3. No I will do that now and get back to you
  4. No, because first I need the used (customer) to pick a value in field 'Application'. So post-function won't work. Just to be a bit more clear: I have an objectType named Application with Objects A (Attribute Type= Incident), Object B (Attribute Type = Request), Object C (attribute Type = Incident). So I want to display to the customer (end user) only Objects A and C based on Jira Custom field which will have the value 'Incident'. So if I change the value of this Jira Custom field to 'Request', the end user will see object B. 

thank you

M Amine
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 13, 2018

for 3. Doesn't work. I have also tried hiding the 'summary' and using the $summary while filling the summary with the right info. Was trying to see if the problem is coming from Insight not supporting custom fields. 

PJ Wysota
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, 2018

OK, so it is more clear now. 

You mismatching some use cases. But to make it faster - here are solutions:

Field Application - to be picked by User - it should be Insight CF with Filter Issue Scope - it should pint out to "ObjectType = Application"

Then Your hidden field - if this is JIRA CF (text/Select) - use post function - Set a Jira custom field with the attribute value from a selected object with setup against your source field = Application, attribute Type, and Target Field name. NOta that with Select - it has to maintain EXACTLY the same values as Type attribute in Insight.

If You want your Type attribute to populate into Insight Field - Type should be Insight object (Insight Fields are not populating attributes directly, they can render attributes along with Objects, but not attribute values instead of objects).

And then setup would require some more sophisticated IQL.



M Amine
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
September 15, 2018

thank you @PJ Wysota for your reply,  But when I read your answser I think that perhaps I didn't explain my use case very well. 

I will try to be clearer. 

  • You have an object type 'Application' and a attribute 'Type'
  • We have 3 objects
    • Confluence Server with Type="On premise"
    • Jira Server  with Type="On premise"
    • Jira Cloud with Type ="Cloud"
  • We have two request types:
    • Request 1: 'Cloud Applications' => I want to display only Jira CLoud
    • Request 2: 'Server Applications' => I want to display the other applications
  • Solutions:
    1. Solution 1: I can use the filter scope with Type = "On Premise" for Request 1 and Type = "Cloud" for Request 2. Please NOTICE that this solution is working PERFECTLY WELL
    2. Solution 2: I want to use placeholders in the IQL. Is it possible? someone can help please?
Like Florian Reichl likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events