dodil/erp-method
modules/payments/signoff/payments/history/payments_cash_day.v1.bpmn
<?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:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:dodil="https://git.dodil.io/dodil/erp-platform/bpmn/1" id="Definitions_payments_v3" name="Payments & collections processes" targetNamespace="https://git.dodil.io/dodil/erp-platform/processes" exporter="erp-platform erp-compose bpmn" exporterVersion="1">
<bpmn:collaboration id="Collaboration_payments_v3">
<bpmn:documentation>Payments & collections: one pool per entity lifecycle, generated from module.yaml.</bpmn:documentation>
<bpmn:participant id="Participant_payments_cash_day" name="Cash day" processRef="Process_payments_cash_day_v3" />
</bpmn:collaboration>
<bpmn:process id="Process_payments_cash_day_v3" name="Cash day" isExecutable="false">
<bpmn:documentation>Lifecycle of the cash day, generated from module.yaml by erp-compose bpmn; change the workflow there, not this file. States: open, closed.</bpmn:documentation>
<bpmn:laneSet id="LaneSet_cash_day">
<bpmn:lane id="Lane_cash_day_cashier" name="Whoever records money (bookkeeper, office manager)">
<bpmn:flowNodeRef>Start_cash_day</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Task_open_cash_day</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Task_record_cash_entry</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Task_count_cash</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Task_close_cash_day</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Gateway_record_cash_entry__if</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Gateway_record_cash_entry__if_end</bpmn:flowNodeRef>
<bpmn:flowNodeRef>End_cash_day_closed</bpmn:flowNodeRef>
</bpmn:lane>
<bpmn:lane id="Lane_cash_day_approver" name="Owner / finance manager">
<bpmn:flowNodeRef>Task_approve_cash_difference</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Gateway_approve_cash_difference__if</bpmn:flowNodeRef>
<bpmn:flowNodeRef>Gateway_approve_cash_difference__if_end</bpmn:flowNodeRef>
</bpmn:lane>
</bpmn:laneSet>
<bpmn:startEvent id="Start_cash_day" name="Cash day needed">
<bpmn:outgoing>Flow_Start_cash_day__Task_open_cash_day</bpmn:outgoing>
</bpmn:startEvent>
<bpmn:userTask id="Task_open_cash_day" name="Open the cash journal's day (v3)" dodil:step="open_cash_day">
<bpmn:documentation>By: Whoever records money (bookkeeper, office manager). From none to open. When: the previous day is closed; today in business_timezone. Effect: the opening balance is the last counted balance.</bpmn:documentation>
<bpmn:incoming>Flow_Start_cash_day__Task_open_cash_day</bpmn:incoming>
<bpmn:outgoing>Flow_Task_open_cash_day__Gateway_record_cash_entry__if</bpmn:outgoing>
</bpmn:userTask>
<bpmn:userTask id="Task_record_cash_entry" name="Record a cash receipt" dodil:step="record_cash_entry">
<bpmn:documentation>By: Whoever records money (bookkeeper, office manager). From open to open. When: dated today; an expense has an account and a tax code. Effect: a receipt, a posting with tax's VAT, or a transfer to the bank (PAY-26).</bpmn:documentation>
<bpmn:incoming>Flow_Gateway_record_cash_entry__if__Task_record_cash_entry</bpmn:incoming>
<bpmn:outgoing>Flow_Task_record_cash_entry__Gateway_record_cash_entry__if_end</bpmn:outgoing>
</bpmn:userTask>
<bpmn:userTask id="Task_count_cash" name="Count the cash" dodil:step="count_cash">
<bpmn:documentation>By: Whoever records money (bookkeeper, office manager). From open to open. Effect: the counted amount, by denomination.</bpmn:documentation>
<bpmn:incoming>Flow_Gateway_record_cash_entry__if_end__Task_count_cash</bpmn:incoming>
<bpmn:outgoing>Flow_Task_count_cash__Gateway_approve_cash_difference__if</bpmn:outgoing>
</bpmn:userTask>
<bpmn:userTask id="Task_close_cash_day" name="Close the day" dodil:step="close_cash_day">
<bpmn:documentation>By: Whoever records money (bookkeeper, office manager). From open to closed. When: counted; a difference above cash_difference_threshold approved by an approver who is not the cashier. Effect: the difference posted to cash over/short; the day refuses entries.</bpmn:documentation>
<bpmn:incoming>Flow_Gateway_approve_cash_difference__if_end__Task_close_cash_day</bpmn:incoming>
<bpmn:outgoing>Flow_Task_close_cash_day__End_cash_day_closed</bpmn:outgoing>
</bpmn:userTask>
<bpmn:userTask id="Task_approve_cash_difference" name="Approve a cash difference" dodil:step="approve_cash_difference" dodil:approval="true">
<bpmn:documentation>By: Owner / finance manager. From open to open. When: the approver is not the person who counted. Requires: reason. An approval.</bpmn:documentation>
<bpmn:incoming>Flow_Gateway_approve_cash_difference__if__Task_approve_cash_difference</bpmn:incoming>
<bpmn:outgoing>Flow_Task_approve_cash_difference__Gateway_approve_cash_difference__if_end</bpmn:outgoing>
</bpmn:userTask>
<bpmn:exclusiveGateway id="Gateway_record_cash_entry__if" name="dated today; an expense has an account and a tax code?">
<bpmn:incoming>Flow_Task_open_cash_day__Gateway_record_cash_entry__if</bpmn:incoming>
<bpmn:outgoing>Flow_Gateway_record_cash_entry__if__Task_record_cash_entry</bpmn:outgoing>
<bpmn:outgoing>Flow_Gateway_record_cash_entry__if__Gateway_record_cash_entry__if_end</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:exclusiveGateway id="Gateway_record_cash_entry__if_end">
<bpmn:incoming>Flow_Gateway_record_cash_entry__if__Gateway_record_cash_entry__if_end</bpmn:incoming>
<bpmn:incoming>Flow_Task_record_cash_entry__Gateway_record_cash_entry__if_end</bpmn:incoming>
<bpmn:outgoing>Flow_Gateway_record_cash_entry__if_end__Task_count_cash</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:exclusiveGateway id="Gateway_approve_cash_difference__if" name="the approver is not the person who counted?">
<bpmn:incoming>Flow_Task_count_cash__Gateway_approve_cash_difference__if</bpmn:incoming>
<bpmn:outgoing>Flow_Gateway_approve_cash_difference__if__Task_approve_cash_difference</bpmn:outgoing>
<bpmn:outgoing>Flow_Gateway_approve_cash_difference__if__Gateway_approve_cash_difference__if_end</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:exclusiveGateway id="Gateway_approve_cash_difference__if_end">
<bpmn:incoming>Flow_Gateway_approve_cash_difference__if__Gateway_approve_cash_difference__if_end</bpmn:incoming>
<bpmn:incoming>Flow_Task_approve_cash_difference__Gateway_approve_cash_difference__if_end</bpmn:incoming>
<bpmn:outgoing>Flow_Gateway_approve_cash_difference__if_end__Task_close_cash_day</bpmn:outgoing>
</bpmn:exclusiveGateway>
<bpmn:endEvent id="End_cash_day_closed" name="Cash day closed">
<bpmn:incoming>Flow_Task_close_cash_day__End_cash_day_closed</bpmn:incoming>
</bpmn:endEvent>
<bpmn:sequenceFlow id="Flow_Start_cash_day__Task_open_cash_day" sourceRef="Start_cash_day" targetRef="Task_open_cash_day" />
<bpmn:sequenceFlow id="Flow_Gateway_record_cash_entry__if__Task_record_cash_entry" name="dated today; an expense has an account and a tax code" sourceRef="Gateway_record_cash_entry__if" targetRef="Task_record_cash_entry" />
<bpmn:sequenceFlow id="Flow_Gateway_record_cash_entry__if__Gateway_record_cash_entry__if_end" name="otherwise" sourceRef="Gateway_record_cash_entry__if" targetRef="Gateway_record_cash_entry__if_end" />
<bpmn:sequenceFlow id="Flow_Task_record_cash_entry__Gateway_record_cash_entry__if_end" sourceRef="Task_record_cash_entry" targetRef="Gateway_record_cash_entry__if_end" />
<bpmn:sequenceFlow id="Flow_Gateway_approve_cash_difference__if__Task_approve_cash_difference" name="the approver is not the person who counted" sourceRef="Gateway_approve_cash_difference__if" targetRef="Task_approve_cash_difference" />
<bpmn:sequenceFlow id="Flow_Gateway_approve_cash_difference__if__Gateway_approve_cash_difference__if_end" name="otherwise" sourceRef="Gateway_approve_cash_difference__if" targetRef="Gateway_approve_cash_difference__if_end" />
<bpmn:sequenceFlow id="Flow_Task_approve_cash_difference__Gateway_approve_cash_difference__if_end" sourceRef="Task_approve_cash_difference" targetRef="Gateway_approve_cash_difference__if_end" />
<bpmn:sequenceFlow id="Flow_Gateway_record_cash_entry__if_end__Task_count_cash" sourceRef="Gateway_record_cash_entry__if_end" targetRef="Task_count_cash" />
<bpmn:sequenceFlow id="Flow_Task_count_cash__Gateway_approve_cash_difference__if" sourceRef="Task_count_cash" targetRef="Gateway_approve_cash_difference__if" />
<bpmn:sequenceFlow id="Flow_Gateway_approve_cash_difference__if_end__Task_close_cash_day" sourceRef="Gateway_approve_cash_difference__if_end" targetRef="Task_close_cash_day" />
<bpmn:sequenceFlow id="Flow_Task_open_cash_day__Gateway_record_cash_entry__if" sourceRef="Task_open_cash_day" targetRef="Gateway_record_cash_entry__if" />
<bpmn:sequenceFlow id="Flow_Task_close_cash_day__End_cash_day_closed" sourceRef="Task_close_cash_day" targetRef="End_cash_day_closed" />
</bpmn:process>
<bpmndi:BPMNDiagram id="BPMNDiagram_payments_v3">
<bpmndi:BPMNPlane id="BPMNPlane_payments_v3" bpmnElement="Collaboration_payments_v3">
<bpmndi:BPMNShape id="Participant_payments_cash_day_di" bpmnElement="Participant_payments_cash_day" isHorizontal="true">
<dc:Bounds x="0" y="0" width="1640" height="520" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Lane_cash_day_cashier_di" bpmnElement="Lane_cash_day_cashier" isHorizontal="true">
<dc:Bounds x="30" y="0" width="1610" height="260" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Lane_cash_day_approver_di" bpmnElement="Lane_cash_day_approver" isHorizontal="true">
<dc:Bounds x="30" y="260" width="1610" height="260" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Start_cash_day_di" bpmnElement="Start_cash_day">
<dc:Bounds x="157" y="42" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Task_open_cash_day_di" bpmnElement="Task_open_cash_day">
<dc:Bounds x="295" y="20" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Task_record_cash_entry_di" bpmnElement="Task_record_cash_entry">
<dc:Bounds x="635" y="20" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Task_count_cash_di" bpmnElement="Task_count_cash">
<dc:Bounds x="805" y="20" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Task_close_cash_day_di" bpmnElement="Task_close_cash_day">
<dc:Bounds x="1315" y="20" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Task_approve_cash_difference_di" bpmnElement="Task_approve_cash_difference">
<dc:Bounds x="1145" y="280" width="100" height="80" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Gateway_record_cash_entry__if_di" bpmnElement="Gateway_record_cash_entry__if">
<dc:Bounds x="490" y="35" width="50" height="50" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Gateway_record_cash_entry__if_end_di" bpmnElement="Gateway_record_cash_entry__if_end">
<dc:Bounds x="660" y="155" width="50" height="50" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Gateway_approve_cash_difference__if_di" bpmnElement="Gateway_approve_cash_difference__if">
<dc:Bounds x="1000" y="295" width="50" height="50" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="Gateway_approve_cash_difference__if_end_di" bpmnElement="Gateway_approve_cash_difference__if_end">
<dc:Bounds x="1170" y="415" width="50" height="50" />
</bpmndi:BPMNShape>
<bpmndi:BPMNShape id="End_cash_day_closed_di" bpmnElement="End_cash_day_closed">
<dc:Bounds x="1517" y="42" width="36" height="36" />
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge id="Flow_Start_cash_day__Task_open_cash_day_di" bpmnElement="Flow_Start_cash_day__Task_open_cash_day">
<di:waypoint x="193" y="60" />
<di:waypoint x="295" y="60" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Gateway_record_cash_entry__if__Task_record_cash_entry_di" bpmnElement="Flow_Gateway_record_cash_entry__if__Task_record_cash_entry">
<di:waypoint x="540" y="60" />
<di:waypoint x="635" y="60" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Gateway_record_cash_entry__if__Gateway_record_cash_entry__if_end_di" bpmnElement="Flow_Gateway_record_cash_entry__if__Gateway_record_cash_entry__if_end">
<di:waypoint x="540" y="60" />
<di:waypoint x="635" y="60" />
<di:waypoint x="635" y="180" />
<di:waypoint x="660" y="180" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Task_record_cash_entry__Gateway_record_cash_entry__if_end_di" bpmnElement="Flow_Task_record_cash_entry__Gateway_record_cash_entry__if_end">
<di:waypoint x="685" y="100" />
<di:waypoint x="685" y="220" />
<di:waypoint x="685" y="220" />
<di:waypoint x="685" y="205" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Gateway_approve_cash_difference__if__Task_approve_cash_difference_di" bpmnElement="Flow_Gateway_approve_cash_difference__if__Task_approve_cash_difference">
<di:waypoint x="1050" y="320" />
<di:waypoint x="1145" y="320" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Gateway_approve_cash_difference__if__Gateway_approve_cash_difference__if_end_di" bpmnElement="Flow_Gateway_approve_cash_difference__if__Gateway_approve_cash_difference__if_end">
<di:waypoint x="1050" y="320" />
<di:waypoint x="1145" y="320" />
<di:waypoint x="1145" y="440" />
<di:waypoint x="1170" y="440" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Task_approve_cash_difference__Gateway_approve_cash_difference__if_end_di" bpmnElement="Flow_Task_approve_cash_difference__Gateway_approve_cash_difference__if_end">
<di:waypoint x="1195" y="360" />
<di:waypoint x="1195" y="486" />
<di:waypoint x="1195" y="486" />
<di:waypoint x="1195" y="465" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Gateway_record_cash_entry__if_end__Task_count_cash_di" bpmnElement="Flow_Gateway_record_cash_entry__if_end__Task_count_cash">
<di:waypoint x="710" y="180" />
<di:waypoint x="780" y="180" />
<di:waypoint x="780" y="60" />
<di:waypoint x="805" y="60" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Task_count_cash__Gateway_approve_cash_difference__if_di" bpmnElement="Flow_Task_count_cash__Gateway_approve_cash_difference__if">
<di:waypoint x="905" y="60" />
<di:waypoint x="975" y="60" />
<di:waypoint x="975" y="320" />
<di:waypoint x="1000" y="320" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Gateway_approve_cash_difference__if_end__Task_close_cash_day_di" bpmnElement="Flow_Gateway_approve_cash_difference__if_end__Task_close_cash_day">
<di:waypoint x="1220" y="440" />
<di:waypoint x="1290" y="440" />
<di:waypoint x="1290" y="60" />
<di:waypoint x="1315" y="60" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Task_open_cash_day__Gateway_record_cash_entry__if_di" bpmnElement="Flow_Task_open_cash_day__Gateway_record_cash_entry__if">
<di:waypoint x="395" y="60" />
<di:waypoint x="490" y="60" />
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge id="Flow_Task_close_cash_day__End_cash_day_closed_di" bpmnElement="Flow_Task_close_cash_day__End_cash_day_closed">
<di:waypoint x="1415" y="60" />
<di:waypoint x="1517" y="60" />
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</bpmn:definitions>