endOrder
endOrder(
step,worker,endOrderOptions?):void
Ends worker’s order: it emits OrderEndedEvent, stops the walk, and
the worker’s routine goes back to the routine and step the order
interrupted. A worker with no order is left as it is.
Parameters
Section titled “Parameters”| Parameter | Type |
|---|---|
step |
AuthoritativeStep |
worker |
Entity |
endOrderOptions |
EndOrderOptions |
Returns
Section titled “Returns”void
Example
Section titled “Example”endOrder(step, worker, { reason: OrderEndReason.Cancelled });