$customHeader
Skip to end of metadata
Go to start of metadata

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

Compare with Current View Page History

Version 1 Next »

Summary

Scriptlets are able to retrieve values from most Jira Fields and these field values can be used for a variety of different features within the Scriptlet. Scriptlets are used to provide pre-defined sections of Html content for Ad-Hoc notifications.

Example Scriptlet

This Scriptlet example gathers all of the Jira Field values and displays them in a format that is similar to the Jira Issue Page.

There are two features that have been implemented within this Scriptlet to restrict any unnecessary content from being shown within the Ad-Hoc notification:

  1. Check if Fields are empty. If empty they will not be shown.

  2. Check if comments are internal comments. If they are internal comment then they will not be shown. This only applies to Jira Service Desk Projects.

For the Request Participant and Organisation fields to be shown, the Custom Field Id’s must be changed within the Scriptlet to match your Jira instance. Custom Fields that are created by users will not be gathered by this Scriptlet and would require further configuration.

Below is the Scriptlet File:

Importing the example Scriptlet

To import the Scriptlet go to JEMH > Template Sets > Templates > Import Template Set and select the Downloaded Scriptlet file. This will then place the Scriptlet within the “Scriptlets for Ad hoc” section in Template Sets.

Inserting a Scriplet into a Ad-Hoc notification

To insert the Scriptlet into the Ad-Hoc notification press Insert > Add Template within the the text editor. This will then display the content into the Comment text editor.

Example Email that used this Scriptlet

Below is a demonstration of how the Scriptlet content is displayed within an email.

  • No labels