<?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" targetNamespace="http://bpmn.io/schema/bpmn" id="Definitions_MTO">
  <bpmn:process id="Process_MTO" isExecutable="false">
    <bpmn:startEvent id="SE_Start" name="PO Accepted"><bpmn:outgoing>SF_1</bpmn:outgoing></bpmn:startEvent>
    <bpmn:userTask id="T_Order" name="Create Sales Order"><bpmn:incoming>SF_1</bpmn:incoming><bpmn:outgoing>SF_2</bpmn:outgoing></bpmn:userTask>
    <bpmn:serviceTask id="T_Credit" name="Credit Check"><bpmn:incoming>SF_2</bpmn:incoming><bpmn:outgoing>SF_3</bpmn:outgoing></bpmn:serviceTask>
    <bpmn:exclusiveGateway id="GW_Credit" name="Credit OK?"><bpmn:incoming>SF_3</bpmn:incoming><bpmn:outgoing>SF_OK</bpmn:outgoing><bpmn:outgoing>SF_Block</bpmn:outgoing></bpmn:exclusiveGateway>
    <bpmn:userTask id="T_Produce" name="Plan and Produce"><bpmn:incoming>SF_OK</bpmn:incoming><bpmn:outgoing>SF_4</bpmn:outgoing></bpmn:userTask>
    <bpmn:userTask id="T_Quality" name="Quality Check"><bpmn:incoming>SF_4</bpmn:incoming><bpmn:outgoing>SF_5</bpmn:outgoing></bpmn:userTask>
    <bpmn:userTask id="T_Ship" name="Pick Pack Ship"><bpmn:incoming>SF_5</bpmn:incoming><bpmn:outgoing>SF_6</bpmn:outgoing></bpmn:userTask>
    <bpmn:userTask id="T_Invoice" name="Create Invoice"><bpmn:incoming>SF_6</bpmn:incoming><bpmn:outgoing>SF_7</bpmn:outgoing></bpmn:userTask>
    <bpmn:endEvent id="SE_Done" name="Invoiced"><bpmn:incoming>SF_7</bpmn:incoming></bpmn:endEvent>
    <bpmn:endEvent id="SE_Block" name="Order Blocked"><bpmn:incoming>SF_Block</bpmn:incoming></bpmn:endEvent>
    <bpmn:sequenceFlow id="SF_1" sourceRef="SE_Start" targetRef="T_Order"/>
    <bpmn:sequenceFlow id="SF_2" sourceRef="T_Order" targetRef="T_Credit"/>
    <bpmn:sequenceFlow id="SF_3" sourceRef="T_Credit" targetRef="GW_Credit"/>
    <bpmn:sequenceFlow id="SF_OK" name="OK" sourceRef="GW_Credit" targetRef="T_Produce"/>
    <bpmn:sequenceFlow id="SF_Block" name="Blocked" sourceRef="GW_Credit" targetRef="SE_Block"/>
    <bpmn:sequenceFlow id="SF_4" sourceRef="T_Produce" targetRef="T_Quality"/>
    <bpmn:sequenceFlow id="SF_5" sourceRef="T_Quality" targetRef="T_Ship"/>
    <bpmn:sequenceFlow id="SF_6" sourceRef="T_Ship" targetRef="T_Invoice"/>
    <bpmn:sequenceFlow id="SF_7" sourceRef="T_Invoice" targetRef="SE_Done"/>
  </bpmn:process>
  <bpmndi:BPMNDiagram id="BPMNDiagram_1">
    <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Process_MTO">
      <bpmndi:BPMNShape id="Sh_SE_Start" bpmnElement="SE_Start"><dc:Bounds x="52" y="182" width="36" height="36"/><bpmndi:BPMNLabel><dc:Bounds x="38" y="225" width="65" height="14"/></bpmndi:BPMNLabel></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_T_Order" bpmnElement="T_Order"><dc:Bounds x="140" y="160" width="110" height="80"/></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_T_Credit" bpmnElement="T_Credit"><dc:Bounds x="310" y="160" width="110" height="80"/></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_GW_Credit" bpmnElement="GW_Credit" isMarkerVisible="true"><dc:Bounds x="480" y="175" width="50" height="50"/><bpmndi:BPMNLabel><dc:Bounds x="468" y="232" width="74" height="27"/></bpmndi:BPMNLabel></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_T_Produce" bpmnElement="T_Produce"><dc:Bounds x="590" y="160" width="110" height="80"/></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_T_Quality" bpmnElement="T_Quality"><dc:Bounds x="760" y="160" width="110" height="80"/></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_T_Ship" bpmnElement="T_Ship"><dc:Bounds x="930" y="160" width="110" height="80"/></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_T_Invoice" bpmnElement="T_Invoice"><dc:Bounds x="1100" y="160" width="110" height="80"/></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_SE_Done" bpmnElement="SE_Done"><dc:Bounds x="1262" y="182" width="36" height="36"/><bpmndi:BPMNLabel><dc:Bounds x="1252" y="225" width="56" height="14"/></bpmndi:BPMNLabel></bpmndi:BPMNShape>
      <bpmndi:BPMNShape id="Sh_SE_Block" bpmnElement="SE_Block"><dc:Bounds x="480" y="332" width="36" height="36"/><bpmndi:BPMNLabel><dc:Bounds x="458" y="375" width="80" height="27"/></bpmndi:BPMNLabel></bpmndi:BPMNShape>
      <bpmndi:BPMNEdge id="Ed_SF_1" bpmnElement="SF_1"><di:waypoint x="88" y="200"/><di:waypoint x="140" y="200"/></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_2" bpmnElement="SF_2"><di:waypoint x="250" y="200"/><di:waypoint x="310" y="200"/></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_3" bpmnElement="SF_3"><di:waypoint x="420" y="200"/><di:waypoint x="480" y="200"/></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_OK" bpmnElement="SF_OK"><di:waypoint x="530" y="200"/><di:waypoint x="590" y="200"/><bpmndi:BPMNLabel><dc:Bounds x="542" y="182" width="18" height="14"/></bpmndi:BPMNLabel></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_Block" bpmnElement="SF_Block"><di:waypoint x="505" y="225"/><di:waypoint x="505" y="332"/><bpmndi:BPMNLabel><dc:Bounds x="511" y="270" width="42" height="14"/></bpmndi:BPMNLabel></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_4" bpmnElement="SF_4"><di:waypoint x="700" y="200"/><di:waypoint x="760" y="200"/></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_5" bpmnElement="SF_5"><di:waypoint x="870" y="200"/><di:waypoint x="930" y="200"/></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_6" bpmnElement="SF_6"><di:waypoint x="1040" y="200"/><di:waypoint x="1100" y="200"/></bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge id="Ed_SF_7" bpmnElement="SF_7"><di:waypoint x="1210" y="200"/><di:waypoint x="1262" y="200"/></bpmndi:BPMNEdge>
    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>
</bpmn:definitions>
