SLARepair - repairByFilter(String filter, String sourceTable)

Repair the task SLAs associated with the passed-in filter and source table.

Table 1. Parameters
Name Type Description
filter string Specify an encoded query that is used to retrieve a set of records from the source table.
sourceTable string Specify the name of a table that is (or extends) contract_sla, task_sla, or task.
Table 2. Returns
Type Description

Find problems created last month with a priority of 2

var gr = new GlideRecord("problem");
gr.addQuery("sys_created_on", "ON", "Last Month@javascript:gs.beginningOfLastMonth()@javascript:gs.endOfLastMonth()");
gr.addQuery("priority", "2");

var repair = new SLARepair();
repair.repairByFilter(gr.getEncodedQuery(), gr.getRecordClassName());