Invalid license: Your Refined is only licensed for 10 users.

You are viewing an old version of this page. View the current version.

Compare with Current View Page History

Version 1 Next »

This article explains how to render attributes of Asset type objects connected to JSM requests.


Assets objects is a feature supported by JSM Premium edition and allows you to configure and maintain a collection of objects that work in a Map-like way. These objects may be used to represent physical entities, such as hardware, machinery or office buildings as well as non-tangible assets, like configurations, contracts etc.


The common scenario is that a JSM request has a link to specific Asset object and we need to show it in a customer-facing notification. We'll use the field called "Linked Assets" as example in this tutorial.


Here's how you render its attributes in Raley:


1) In Issue field picker choose the field "Linked Assets". You'll be presented with a popup which contains code similar to the following:

#foreach($o in $!issue.fields.customfield_10050)
 $jirassimo.getAssetFieldValue($o.objectId, "ATTRIBUTE_NAME")
#end


Note that our Linked Assets field is customfield_10050 and it is a array-type field that we need to iterate using #foreach statement


2) Replace the ATTRIBUTE_NAME placeholder by the name of the attribute you want to render. Let's say the attribute name is "OT1 attribute". In that case, our code should look like this:

#foreach($o in $!issue.fields.customfield_10050)
 $jirassimo.getAssetFieldValue($o.objectId, "OT1 attribute")
#end


That's it! Preview the notification configuration and you'll see the value of connected Asset field's attribute "OT1 attribute".