Hi,
We would like to add all info of our customers deployment in Insight Asset Management.
Then, when the customer creates JSD ticket, show the CMDB info related to this customer in the issue to the support agent.
We would link both using the 'Organisations' field, using the organisation ID.
In the issue I have a automatically filled customfield, called 'Organization ID' which contains the ID of the organisation linked to the issue.
In the CMDB we have Customers with an attribute 'Org_ID' that contains the same info.
How now show the Customer Insight Object in the issue?
I tried creating an Insight Custom Field and set the Filter Assign Scope to "objectType = Customer AND Customer.Org_ID = ${customfield_22901.label}" but this is not working.
I want the exact things, did you find the solution?
Hi,
To make it work with the organization field, we used an automation that executes a scriptrunner script after the creation.
After testing and extra requirement to make it work in non service desk projects that do not have organizations, we switched to using another custom field that we have and that has the same values as the Organizations.
This field was already in use and was mainly set-up to be able to us customers in gadgets on dashboards (which is not possible with the organizations field).
This custom field is automatically filled using a Scriptrunner listener that runs after the creation of a ticket and can be manually adjusted if needed (fex when a reporter belongs to 2 organizations).
We than have the assign scope in the Insight Custom Field as follows:
objectType = Customers AND Name = ${customfield_19801.name}
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Wim,
I have a similar situation in my instance I resolve this adding a script into the workflow in the creation transition. I my example I use the reporter username but you could use the customfield_22901
def customField = ComponentAccessor.getCustomFieldManager().getCustomFieldObject("customfield_22901");
def value = (String)issue.getCustomFieldValue(customField);
import com.atlassian.jira.component.ComponentAccessor;
import com.atlassian.jira.issue.fields.CustomField;
import com.atlassian.jira.issue.Issue;
import com.atlassian.jira.issue.MutableIssue;
import com.atlassian.jira.event.type.EventDispatchOption;
/* Insight custom field to set */
CustomField insightCF = ComponentAccessor.getCustomFieldManager().getCustomFieldObject(XXXX);
if (insightCF == null) {
return true;
}
/* Get Insight IQL Facade from plugin accessor */
Class iqlFacadeClass = ComponentAccessor.getPluginAccessor().getClassLoader().findClass("com.riadalabs.jira.plugins.insight.channel.external.api.facade.IQLFacade");
def iqlFacade = ComponentAccessor.getOSGiComponentInstanceOfType(iqlFacadeClass);
/* Specify the schema id as well as the IQL that will fetch objects. In this case all objects with Name matching the valueCF, be sure to include " around value */
def objects = iqlFacade.findObjectsByIQLAndSchema(X, "YOUR IQL)");
if (!objects.isEmpty()) {
MutableIssue mi = (MutableIssue) issue;
mi.setCustomFieldValue(insightCF, objects);
ComponentAccessor.getIssueManager().updateIssue(currentUser, mi, EventDispatchOption.DO_NOT_DISPATCH, false);
}
return true;
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.