Dynamically assign fields from alerts to its associated task

Use the EvtMgmtCustomIncidentPopulator script to dynamically assign alert fields to the task template.

Before you begin

Role required: evt_mgmt_admin

About this task

Add a custom script to the EvtMgmtCustomIncidentPopulator placeholder to assign fields from the alert to fields that you specify in the task. For example, use the custom script to query any table and to assign the value of the alert Severity field to the Short description field in the task.

Procedure

  1. Navigate to System UI > Script Includes.
  2. Edit the EvtMgmtCustomIncidentPopulator script to assign fields from the alert to the task that is opened by default to an incident.
  3. Click Update.

Result

The custom script runs against each alert update.

Example

Assume that the current resource type must appear in the Short description field of the alert. Enter this script in the EvtMgmtCustomIncidentPopulator placeholder:
task.short_description += ' resource: ' + alert.resource;
return true;