Develop > Tailoring > Web tier > Example: Notifying specified operators upon an incident update

Example: Notifying specified operators upon an incident update

This example specifies a group of operators that will receive a notification when an incident is updated.

Note The notification will not be sent to a specified operator if the incident is created or updated when the operator is offline.

Add a Script Library record

  1. Execute the sl command in the command line.
  2. In the Name field, enter IncidentMsg1.
  3. Select a package in the Package field.
  4. Enter the following script in the text box below:

    system.functions.msg("Incident "+vars.$file.number+" updated successfully by: "+vars.$ , 1, ["falcon","Incident.Manager"], "popup", 1);

    You need to specify each of the operators in the script. The example script above specifies that falcon and Incident Manager will receive the notification of an incident update.

    Note The script above is an example for Service Manager 9.32. If you use a previous version of Service Manager, change vars.$file.number to vars.$L_file.number.

  5. Click Add.
  6. Click Compile.

Update the process

  1. Click Tailoring > Document Engine > Processes
  2. Search the process.
  3. Select the RAD tab of the process.
  4. Scroll down until you find the first empty RAD Application.
  5. Add the following script in the Post RAD Expression field of the empty RAD Application:

    if $L.continue then ($L.void=jscall("IncidentMsg1"))
  6. Click Save.