JavaScript Triggers
The i-net HelpDesk has a JavaScript interface. In the program code is stored that on certain occasions external logic of a text file can be evaluated. This text file must be newly created and stored in a directory to which the i-net HelpDesk server has access. Afterwards the text file is assigned to the appropriate following triggers.
First of all, here are some examples of logic in a JavaScript file:
-
Auto-mail to end users should be sent in German or English depending on the user language.
-
Notification mails triggered via SNMP trap should not return auto-mails.
-
Content from an HTML mail should be linked to ticket fields. The HTML mail was created by filling out an HTML form.
-
When the status of the ticket is changed in ticket processing, an additional Auto-Mail is to be sent to the end user.
JavaScripts can be used for the following occasions (triggers). Details about the implementation of JavaScript in the i-net HelpDesk can be found here.
New request email arrived
Allows to control a ticket to be newly created by a read-in e-mail. For example, strings can be searched for in the e-mail headers, the subject or the text and thus ticket fields can be pre-filled. The available, changeable fields are documented here.
New answer email arrived
This trigger is used to process tickets to which a customer has written an email response. The available, modifiable fields are documented here.
Example: In case of customer response via email, a possible reactivation should not send the ticket to the closing resource but to a central resource.
Auto-email sent
Allows, for example, setting fields of an email before it is sent. The available, changeable fields are documented here.
Example: Auto-mails to specific recipients get a different sender.
Ticket status changed
This trigger is executed when the status of a ticket changes. The available fields that can be changed are documented here.
Note: The JavaScript of this trigger has to implement the additional method getStatus
(see JavaScript in i-net HelpDesk) so that it can be determined from which ticket state the change triggers this trigger.
Example: If a ticket gets the self-defined status "Release to test", then an automatic email with the Mail template "Release to test" should be sent to the customer (email address of the ticket owner).
Option for JavaScript
The option to send an auto-email, even if the status of a ticket remains unchanged as a result of further processing, causes an auto-email to always be sent when this trigger is applied.
The background for this option is that normally no auto-email is sent if the subsequent status of a processing step is identical to the current status of the ticket.
ITIL process changed
Sending auto-mails when the ITIL process changes. The available changeable fields are documented here.
User manually created a ticket
This trigger is executed whenever a user makes a new own inquiry. The available, modifiable fields are documented here.
Example: A special priority should be set for a new user inquiry and only if the ticket is assigned to a specific resource.
Reload and validate trigger
On the one hand you have the possibility to let the i-net HelpDesk server read changes in an existing JavaScript file immediately. On the other hand, it checks whether the syntax, not the logic, of the JavaScript file is valid.