K Invoking the PMF Workflow from backend
This appendix describes invoking the Process Modeller Framework (PMF) workflow from
the backend for the alert.
Table K-1 PMF Workflow Invoking Parameters
Parameter Name | Parameter Description |
---|---|
Object ID | This represents the unique object ID. For Sanctions, the object ID can be alert ID or Good Guy Whitelist ID. |
Object Type | This represents the object type for the object ID. For Sanctions, the object type will be 301 for alert and 302 for Good Guy Whitelist. |
Infodom | This represents the name of the infodom in which Sanctions are installed. |
Segment |
This represents the name of the segment. For Sanctions, it will be TFLSEGMENT. |
User ID | This represents the User ID that is triggering the workflow. Pass the value as SYSTEM. |
Locale | This represents the locale. Pass the value as en_US. |
Application Params | This represents the list of workflow data fields with their respective value. |
Security Params | This represents the list of workflow security data fields with their respective value. |
To trigger the workflow for Sanctions Alerts, follow the below code
snippet.
DECLARE
lv_infodom varchar2(4000);
lv_segment varchar2(4000);
TYPE alert_record_ids IS TABLE OF fsi_rt_alerts.n_grp_msg_id%TYPE;
l_alert_record_ids alert_record_ids;
appParams array_varchar := array_varchar();
secMap array_varchar := array_varchar();
BEGIN
appParams.extend();
appParams(1) := 'TF_ACTION=MANUAL_CLOSE';
appParams.extend();
appParams(2) := 'Role=SYSTEM';
select t.v_attribute_value1
into lv_infodom
from setup_rt_params t
where t.v_param_name = 'TFLT_INFODOM';
select t.v_attribute_value1
into lv_segment
from setup_rt_params t
where t.v_param_name = 'TFLT_SEGMENT';
select t.n_grp_msg_id bulk collect
into l_alert_record_ids
from fsi_rt_alerts t
where t.n_status_cd in (1,2);
FOR recId IN 1 .. l_alert_record_ids.COUNT loop
startWorkflowForExpireRecord(l_alert_record_ids(recId),
'301',
lv_infodom,
lv_segment,
'SYSTEM',
'en_US',
appParams,
secMap);
end loop;
EXCEPTION
WHEN OTHERS THEN
dbms_output.put_line(SQLCODE || SQLERRM);
ROLLBACK;
END;