104 lines
5.3 KiB
XML
104 lines
5.3 KiB
XML
<?xml version="1.0" encoding="UTF-8"?>
|
|
<bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:spiffworkflow="http://spiffworkflow.org/bpmn/schema/1.0/core" id="Definitions_96f6665" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="5.6.0">
|
|
<bpmn:process id="SR-Start_Process" name="Shared Resources: Start Process" isExecutable="true">
|
|
<bpmn:startEvent id="StartEvent_1">
|
|
<bpmn:outgoing>Flow_1u7dtsr</bpmn:outgoing>
|
|
</bpmn:startEvent>
|
|
<bpmn:sequenceFlow id="Flow_1u7dtsr" sourceRef="StartEvent_1" targetRef="Activity_0i59o4c" />
|
|
<bpmn:scriptTask id="Activity_0i59o4c" name="Get Process Info" scriptFormat="python">
|
|
<bpmn:documentation>Returns dictionary like:
|
|
"process_info": {
|
|
"process_instance_id": 96,
|
|
"process_model_identifier": "execute-procure-to-pay/cc-invoice-approval-process"
|
|
},</bpmn:documentation>
|
|
<bpmn:incoming>Flow_1u7dtsr</bpmn:incoming>
|
|
<bpmn:outgoing>Flow_1m5aamy</bpmn:outgoing>
|
|
<bpmn:script># Get Process Info
|
|
process_info = get_process_info()</bpmn:script>
|
|
</bpmn:scriptTask>
|
|
<bpmn:endEvent id="Event_1ghzw9d">
|
|
<bpmn:incoming>Flow_0w854zv</bpmn:incoming>
|
|
</bpmn:endEvent>
|
|
<bpmn:sequenceFlow id="Flow_1m5aamy" sourceRef="Activity_0i59o4c" targetRef="Activity_0yoy91y" />
|
|
<bpmn:sequenceFlow id="Flow_00fd8n9" sourceRef="Activity_0yoy91y" targetRef="Activity_0437lb9" />
|
|
<bpmn:callActivity id="Activity_0yoy91y" name="Call SR: User Info" calledElement="SR-User_Info">
|
|
<bpmn:extensionElements>
|
|
<spiffworkflow:preScript />
|
|
</bpmn:extensionElements>
|
|
<bpmn:incoming>Flow_1m5aamy</bpmn:incoming>
|
|
<bpmn:outgoing>Flow_00fd8n9</bpmn:outgoing>
|
|
</bpmn:callActivity>
|
|
<bpmn:sequenceFlow id="Flow_0w854zv" sourceRef="Activity_0437lb9" targetRef="Event_1ghzw9d" />
|
|
<bpmn:scriptTask id="Activity_0437lb9" name="Update Current User Info">
|
|
<bpmn:incoming>Flow_00fd8n9</bpmn:incoming>
|
|
<bpmn:outgoing>Flow_0w854zv</bpmn:outgoing>
|
|
<bpmn:script># Update Current User Extras
|
|
current_user_extras = {}
|
|
|
|
# Add User Info DMN Table info
|
|
current_user_extras["bamboo_api_id"] = userBambooId
|
|
current_user_extras["time_zone"] = userTimeZone
|
|
current_user_extras["date_format"] = userDateFormat
|
|
current_user_extras["time_format"] = userTimeFormat
|
|
|
|
# Add Bamboo Info to Extras if Status email
|
|
if is_status_email:
|
|
current_user_extras["first_name"] = bamboo_get_employee["firstName"]
|
|
current_user_extras["last_name"] = bamboo_get_employee["lastName"]
|
|
current_user_extras["preferred_name"] = bamboo_get_employee["preferredName"]
|
|
if current_user_extras["preferred_name"] is None:
|
|
current_user_extras["full_name"] = current_user_extras["first_name"] + " " + current_user_extras["last_name"]
|
|
else:
|
|
current_user_extras["full_name"] = current_user_extras["first_name"] + " (" + current_user_extras["preferred_name"] + ") " + current_user_extras["last_name"]
|
|
current_user_extras["status_key"] = bamboo_get_employee["customStatusChatKey"]
|
|
current_user_extras["bamboo_supervisor_api_id"] = bamboo_get_employee["supervisorEid"]
|
|
current_user_extras["bamboo_supervisor_status_id"] = bamboo_get_employee["supervisorId"]
|
|
|
|
del(userFullName)
|
|
del(userFirstName)
|
|
del(userTimeZone)
|
|
del(userStatusKey)
|
|
del(userBambooId)
|
|
del(userDateFormat)
|
|
del(userTimeFormat)</bpmn:script>
|
|
</bpmn:scriptTask>
|
|
</bpmn:process>
|
|
<bpmndi:BPMNDiagram id="BPMNDiagram_1">
|
|
<bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="SR-Start_Process">
|
|
<bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1">
|
|
<dc:Bounds x="179" y="99" width="36" height="36" />
|
|
</bpmndi:BPMNShape>
|
|
<bpmndi:BPMNShape id="Activity_1f0swho_di" bpmnElement="Activity_0i59o4c">
|
|
<dc:Bounds x="270" y="77" width="100" height="80" />
|
|
<bpmndi:BPMNLabel />
|
|
</bpmndi:BPMNShape>
|
|
<bpmndi:BPMNShape id="Activity_18fbf94_di" bpmnElement="Activity_0yoy91y">
|
|
<dc:Bounds x="440" y="77" width="100" height="80" />
|
|
<bpmndi:BPMNLabel />
|
|
</bpmndi:BPMNShape>
|
|
<bpmndi:BPMNShape id="Event_1ghzw9d_di" bpmnElement="Event_1ghzw9d">
|
|
<dc:Bounds x="812" y="99" width="36" height="36" />
|
|
</bpmndi:BPMNShape>
|
|
<bpmndi:BPMNShape id="Activity_0y9449j_di" bpmnElement="Activity_0437lb9">
|
|
<dc:Bounds x="620" y="77" width="100" height="80" />
|
|
</bpmndi:BPMNShape>
|
|
<bpmndi:BPMNEdge id="Flow_1u7dtsr_di" bpmnElement="Flow_1u7dtsr">
|
|
<di:waypoint x="215" y="117" />
|
|
<di:waypoint x="270" y="117" />
|
|
</bpmndi:BPMNEdge>
|
|
<bpmndi:BPMNEdge id="Flow_1m5aamy_di" bpmnElement="Flow_1m5aamy">
|
|
<di:waypoint x="370" y="117" />
|
|
<di:waypoint x="440" y="117" />
|
|
</bpmndi:BPMNEdge>
|
|
<bpmndi:BPMNEdge id="Flow_00fd8n9_di" bpmnElement="Flow_00fd8n9">
|
|
<di:waypoint x="540" y="117" />
|
|
<di:waypoint x="620" y="117" />
|
|
</bpmndi:BPMNEdge>
|
|
<bpmndi:BPMNEdge id="Flow_0w854zv_di" bpmnElement="Flow_0w854zv">
|
|
<di:waypoint x="720" y="117" />
|
|
<di:waypoint x="812" y="117" />
|
|
</bpmndi:BPMNEdge>
|
|
</bpmndi:BPMNPlane>
|
|
</bpmndi:BPMNDiagram>
|
|
</bpmn:definitions>
|