WorkflowModelManager - getPreviousByTransition(Object haRecord)

Retrieves the history activities that executed just prior to the one provided in the argument. The next status is based on the wf_activity.sys_id associated with the activity represented in the haRecord existing as a TO in a transition associated with any ActivityHistoryRecords that come before the haRecord in the execution sequence. (This differs from getAllTransitionedIntoActivity, which returns all TO transitions up to the given haRecord in the execution sequence .) The return value is a collection of ActivityHistoryRecords that identify the argument haRecord.wfaId as their TO activity. The return values are based on which transitions came before the haRecord submitted and not necessarily the activities that executed just prior to the haRecord in time. To get the activity that executed prior to this activity in time, use getPreviousByExecutedOrder.

The next status is based on the wf_activity.sys_id associated with the activity represented in the haRecord existing as a TO in a transition associated with any ActivityHistoryRecords that come before the haRecord in the execution sequence. (This differs from getAllTransitionedIntoActivity, which returns all TO transitions up to the given haRecord in the execution sequence .) The return value is a collection of ActivityHistoryRecords that identify the argument haRecord.wfaId as their TO activity. The return values are based on which transitions came before the haRecord submitted and not necessarily the activities that executed just prior to the haRecord in time. To get the activity that executed prior to this activity in time, use getPreviousByExecutedOrder.

Table 1. Parameters
Name Type Description
haRecord Object ActivityHistoryRecord JavaScript object.
Table 2. Returns
TypeDescription
Object Array Array of ActivityHistoryRecord JavaScript objects requested.