<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:activiti="http://activiti.org/bpmn" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:omgdc="http://www.omg.org/spec/DD/20100524/DC" xmlns:omgdi="http://www.omg.org/spec/DD/20100524/DI" typeLanguage="http://www.w3.org/2001/XMLSchema" expressionLanguage="http://www.w3.org/1999/XPath" targetNamespace="http://www.activiti.org/test">
  <process id="BusinessManagement" name="业务管理流程" isExecutable="true">
    <exclusiveGateway id="exclusivegateway1" name="Exclusive Gateway"></exclusiveGateway>
    <endEvent id="endevent1" name="End"></endEvent>
    <sequenceFlow id="flow2" name="不投标" sourceRef="exclusivegateway1" targetRef="endevent1">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='不投标'}]]></conditionExpression>
    </sequenceFlow>
    <userTask id="template_review_approval" name="模板审核" activiti:candidateUsers="${template_review_candidate}" activiti:formKey="/template/review/approval"></userTask>
    <sequenceFlow id="flow3" name="投标" sourceRef="exclusivegateway1" targetRef="template_review_approval">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='投标'}]]></conditionExpression>
    </sequenceFlow>
    <startEvent id="startevent1" name="Start"></startEvent>
    <userTask id="business_add" name="业务创建" activiti:assignee="${business_add_assignee}" activiti:formKey="/template/review/add"></userTask>
    <sequenceFlow id="flow4" sourceRef="startevent1" targetRef="business_add"></sequenceFlow>
    <sequenceFlow id="flow5" sourceRef="business_add" targetRef="exclusivegateway1"></sequenceFlow>
    <exclusiveGateway id="exclusivegateway2" name="Exclusive Gateway"></exclusiveGateway>
    <sequenceFlow id="flow7" sourceRef="template_review_approval" targetRef="exclusivegateway2"></sequenceFlow>
    <sequenceFlow id="flow8" name="驳回" sourceRef="exclusivegateway2" targetRef="business_add">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='驳回'}]]></conditionExpression>
    </sequenceFlow>
    <userTask id="guarantee_method_confirm" name="保证方式确认" activiti:assignee="${guarantee_method_confirm_assignee}" activiti:formKey="/guarantee/method/confirm"></userTask>
    <sequenceFlow id="flow9" name="通过" sourceRef="exclusivegateway2" targetRef="guarantee_method_confirm">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='通过'}]]></conditionExpression>
    </sequenceFlow>
    <exclusiveGateway id="exclusivegateway3" name="Exclusive Gateway"></exclusiveGateway>
    <sequenceFlow id="flow10" sourceRef="guarantee_method_confirm" targetRef="exclusivegateway3"></sequenceFlow>
    <sequenceFlow id="flow11" name="保函" sourceRef="exclusivegateway3" targetRef="endevent1">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='保函'}]]></conditionExpression>
    </sequenceFlow>
    <userTask id="margin_collection_confirm" name="保证金收款确认" activiti:candidateUsers="${margin_collection_confirm_candidate}" activiti:formKey="/margin/collection/confirm"></userTask>
    <sequenceFlow id="flow12" name="保证金" sourceRef="exclusivegateway3" targetRef="margin_collection_confirm">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='保证金'}]]></conditionExpression>
    </sequenceFlow>
    <userTask id="award_confirm" name="中标确认" activiti:assignee="${award_confirm_assignee}" activiti:formKey="/award/confirm"></userTask>
    <sequenceFlow id="flow13" sourceRef="margin_collection_confirm" targetRef="award_confirm"></sequenceFlow>
    <exclusiveGateway id="exclusivegateway4" name="Exclusive Gateway"></exclusiveGateway>
    <sequenceFlow id="flow14" sourceRef="award_confirm" targetRef="exclusivegateway4"></sequenceFlow>
    <sequenceFlow id="flow15" name="中标" sourceRef="exclusivegateway4" targetRef="endevent1">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='中标'}]]></conditionExpression>
    </sequenceFlow>
    <userTask id="refund_deposit_confirm" name="保证金退款确认" activiti:assignee="${refund_deposit_confirm_assignee}" activiti:formKey="/refund/deposit/confirm"></userTask>
    <sequenceFlow id="flow16" name="未中标" sourceRef="exclusivegateway4" targetRef="refund_deposit_confirm">
      <conditionExpression xsi:type="tFormalExpression"><![CDATA[${result=='未中标'}]]></conditionExpression>
    </sequenceFlow>
    <endEvent id="endevent2" name="End"></endEvent>
    <sequenceFlow id="flow17" sourceRef="refund_deposit_confirm" targetRef="endevent2"></sequenceFlow>
  </process>
  <bpmndi:BPMNDiagram id="BPMNDiagram_BusinessManagement">
    <bpmndi:BPMNPlane bpmnElement="BusinessManagement" id="BPMNPlane_BusinessManagement">
      <bpmndi:BPMNShape bpmnElement="exclusivegateway1" id="BPMNShape_exclusivegateway1">
        <omgdc:Bounds height="40.0" width="40.0" x="354.0" y="227.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="endevent1" id="BPMNShape_endevent1">
        <omgdc:Bounds height="35.0" width="35.0" x="357.0" y="360.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="template_review_approval" id="BPMNShape_template_review_approval">
        <omgdc:Bounds height="55.0" width="105.0" x="490.0" y="220.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="startevent1" id="BPMNShape_startevent1">
        <omgdc:Bounds height="35.0" width="35.0" x="60.0" y="230.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="business_add" id="BPMNShape_business_add">
        <omgdc:Bounds height="55.0" width="105.0" x="170.0" y="220.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="exclusivegateway2" id="BPMNShape_exclusivegateway2">
        <omgdc:Bounds height="40.0" width="40.0" x="660.0" y="227.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="guarantee_method_confirm" id="BPMNShape_guarantee_method_confirm">
        <omgdc:Bounds height="55.0" width="105.0" x="760.0" y="220.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="exclusivegateway3" id="BPMNShape_exclusivegateway3">
        <omgdc:Bounds height="40.0" width="40.0" x="930.0" y="227.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="margin_collection_confirm" id="BPMNShape_margin_collection_confirm">
        <omgdc:Bounds height="55.0" width="105.0" x="1080.0" y="220.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="award_confirm" id="BPMNShape_award_confirm">
        <omgdc:Bounds height="55.0" width="105.0" x="1080.0" y="410.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="exclusivegateway4" id="BPMNShape_exclusivegateway4">
        <omgdc:Bounds height="40.0" width="40.0" x="940.0" y="417.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="refund_deposit_confirm" id="BPMNShape_refund_deposit_confirm">
        <omgdc:Bounds height="55.0" width="105.0" x="908.0" y="530.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNShape bpmnElement="endevent2" id="BPMNShape_endevent2">
        <omgdc:Bounds height="35.0" width="35.0" x="730.0" y="540.0"></omgdc:Bounds>
      </bpmndi:BPMNShape>
      <bpmndi:BPMNEdge bpmnElement="flow2" id="BPMNEdge_flow2">
        <omgdi:waypoint x="374.0" y="267.0"></omgdi:waypoint>
        <omgdi:waypoint x="374.0" y="360.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="36.0" x="380.0" y="299.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow3" id="BPMNEdge_flow3">
        <omgdi:waypoint x="394.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="490.0" y="247.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="24.0" x="419.0" y="254.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow4" id="BPMNEdge_flow4">
        <omgdi:waypoint x="95.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="170.0" y="247.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow5" id="BPMNEdge_flow5">
        <omgdi:waypoint x="275.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="354.0" y="247.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow7" id="BPMNEdge_flow7">
        <omgdi:waypoint x="595.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="660.0" y="247.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow8" id="BPMNEdge_flow8">
        <omgdi:waypoint x="680.0" y="227.0"></omgdi:waypoint>
        <omgdi:waypoint x="680.0" y="158.0"></omgdi:waypoint>
        <omgdi:waypoint x="222.0" y="158.0"></omgdi:waypoint>
        <omgdi:waypoint x="222.0" y="220.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="24.0" x="440.0" y="141.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow9" id="BPMNEdge_flow9">
        <omgdi:waypoint x="700.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="760.0" y="247.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="24.0" x="709.0" y="227.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow10" id="BPMNEdge_flow10">
        <omgdi:waypoint x="865.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="930.0" y="247.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow11" id="BPMNEdge_flow11">
        <omgdi:waypoint x="950.0" y="267.0"></omgdi:waypoint>
        <omgdi:waypoint x="950.0" y="377.0"></omgdi:waypoint>
        <omgdi:waypoint x="392.0" y="377.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="24.0" x="631.0" y="359.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow12" id="BPMNEdge_flow12">
        <omgdi:waypoint x="970.0" y="247.0"></omgdi:waypoint>
        <omgdi:waypoint x="1080.0" y="247.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="36.0" x="999.0" y="230.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow13" id="BPMNEdge_flow13">
        <omgdi:waypoint x="1132.0" y="275.0"></omgdi:waypoint>
        <omgdi:waypoint x="1132.0" y="410.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow14" id="BPMNEdge_flow14">
        <omgdi:waypoint x="1080.0" y="437.0"></omgdi:waypoint>
        <omgdi:waypoint x="980.0" y="437.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow15" id="BPMNEdge_flow15">
        <omgdi:waypoint x="940.0" y="437.0"></omgdi:waypoint>
        <omgdi:waypoint x="374.0" y="437.0"></omgdi:waypoint>
        <omgdi:waypoint x="374.0" y="395.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="24.0" x="632.0" y="417.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow16" id="BPMNEdge_flow16">
        <omgdi:waypoint x="960.0" y="457.0"></omgdi:waypoint>
        <omgdi:waypoint x="960.0" y="530.0"></omgdi:waypoint>
        <bpmndi:BPMNLabel>
          <omgdc:Bounds height="14.0" width="36.0" x="970.0" y="480.0"></omgdc:Bounds>
        </bpmndi:BPMNLabel>
      </bpmndi:BPMNEdge>
      <bpmndi:BPMNEdge bpmnElement="flow17" id="BPMNEdge_flow17">
        <omgdi:waypoint x="908.0" y="557.0"></omgdi:waypoint>
        <omgdi:waypoint x="765.0" y="557.0"></omgdi:waypoint>
      </bpmndi:BPMNEdge>
    </bpmndi:BPMNPlane>
  </bpmndi:BPMNDiagram>
</definitions>