task.WorkflowTriggerTask
Object Description |
All the properties required to asynchronously initiate a workflow. Use the The task is placed in the scheduling queue, and the workflow instance is initiated after the task reaches the top of the queue.
To use the
Use the following guidelines with the
To initiate a workflow on demand, see workflow.initiate(options). |
Supported Script Types |
Server scripts For more information, see SuiteScript 2.x Script Types. |
Module |
|
Methods and Properties |
|
Since |
2015.2 |
Syntax
The following code sample shows the syntax for this member. It is not a functional example. For a complete script example, see N/task Module Script Samples.
//Add additional code
...
var workflowTask = task.create({
taskType: task.TaskType.WORKFLOW_TRIGGER
});
workflowTask.recordType = 'customer';
workflowTask.recordId = 107;
workflowTask.workflowId = 3;
var taskId = workflowTask.submit();
...
//Add additional code