@witlink/workflow 1.0.12 → 1.0.13

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -28443,7 +28443,7 @@ function eN(e, t) {
28443
28443
  }, null, -1)
28444
28444
  ]));
28445
28445
  }
28446
- const tN = Lm({ name: "ant-design-question-circle", render: eN }), nN = { class: "wrapper" }, iN = { class: "mt-xs" }, rN = { class: "flex-sc" }, oN = { class: "mt-xs" }, aN = { class: "mr-xs" }, sN = /* @__PURE__ */ We({
28446
+ const tN = Lm({ name: "ant-design-question-circle", render: eN }), nN = { class: "wrapper" }, iN = { class: "mt-xs" }, rN = { class: "flex-sc" }, oN = { class: "mt-xs" }, aN = { style: { maxWidth: "281px", overflow: "hidden", whiteSpace: "break-spaces" } }, sN = /* @__PURE__ */ We({
28447
28447
  __name: "RuleConfig",
28448
28448
  props: {
28449
28449
  jsonStr: {
@@ -28498,8 +28498,8 @@ const tN = Lm({ name: "ant-design-question-circle", render: eN }), nN = { class:
28498
28498
  return ne(), St("div", nN, [
28499
28499
  I(w, {
28500
28500
  class: "my-nm",
28501
- "label-col": { span: 6 },
28502
- "wrapper-col": { span: 18 },
28501
+ "label-col": { span: 9 },
28502
+ "wrapper-col": { span: 15 },
28503
28503
  colon: !1,
28504
28504
  model: V(o)
28505
28505
  }, {
@@ -28690,7 +28690,7 @@ const tN = Lm({ name: "ant-design-question-circle", render: eN }), nN = { class:
28690
28690
  ]);
28691
28691
  };
28692
28692
  }
28693
- }), cN = /* @__PURE__ */ Wn(sN, [["__scopeId", "data-v-584e9946"]]), lN = /* @__PURE__ */ We({
28693
+ }), cN = /* @__PURE__ */ Wn(sN, [["__scopeId", "data-v-e5654449"]]), lN = /* @__PURE__ */ We({
28694
28694
  __name: "Process",
28695
28695
  props: /* @__PURE__ */ Zl({
28696
28696
  isEdit: {
@@ -237,4 +237,4 @@
237
237
  <input type="text" spellcheck="false" />
238
238
  </div>
239
239
  <div class="djs-search-results" />
240
- </div>`,re.RESULT_HTML='<div class="djs-search-result"></div>',re.RESULT_PRIMARY_HTML='<div class="djs-search-result-primary"></div>',re.RESULT_SECONDARY_HTML='<p class="djs-search-result-secondary"></p>';const eD={__depends__:[wa,Ra,tn],searchPad:["type",re]};function vp(e,t,n,i){this._elementRegistry=e,this._canvas=n,this._search=i,t.registerProvider(this)}vp.$inject=["elementRegistry","searchPad","canvas","search"],vp.prototype.find=function(e){var t=this._canvas.getRootElements(),n=this._elementRegistry.filter(function(i){return!ge(i)&&!t.includes(i)});return this._search(n.map(i=>({element:i,label:en(i),id:i.id})),e,{keys:["label","id"]}).map(tD)};function tD(e){const{item:{element:t},tokens:n}=e;return{element:t,primaryTokens:n.label,secondaryTokens:n.id}}const nD={__depends__:[eD,Gh],__init__:["bpmnSearch"],bpmnSearch:["type",vp]},iD="M44.7648 11.3263L36.9892 2.64074C36.0451 1.58628 34.5651 0.988708 33.1904 0.988708H5.98667C3.22688 0.988708 0.989624 3.34892 0.989624 6.26039V55.0235C0.989624 57.9349 3.22688 60.2952 5.98667 60.2952H40.966C43.7257 60.2952 45.963 57.9349 45.963 55.0235V14.9459C45.963 13.5998 45.6407 12.3048 44.7648 11.3263Z",rD="M1.03845 48.1347C1.03845 49.3511 1.07295 50.758 1.38342 52.064C1.69949 53.3938 2.32428 54.7154 3.56383 55.6428C6.02533 57.4841 10.1161 58.7685 14.8212 59.6067C19.5772 60.4538 25.1388 60.8738 30.6831 60.8738C36.2276 60.8738 41.7891 60.4538 46.545 59.6067C51.2504 58.7687 55.3412 57.4842 57.8028 55.6429C59.0424 54.7156 59.6673 53.3938 59.9834 52.064C60.2938 50.7579 60.3285 49.351 60.3285 48.1344V13.8415C60.3285 12.6249 60.2938 11.218 59.9834 9.91171C59.6673 8.58194 59.0423 7.2602 57.8027 6.33294C55.341 4.49168 51.2503 3.20723 46.545 2.36914C41.7891 1.522 36.2276 1.10204 30.6831 1.10205C25.1388 1.10206 19.5772 1.52206 14.8213 2.36923C10.1162 3.20734 6.02543 4.49183 3.5639 6.33314C2.32433 7.26038 1.69951 8.58206 1.38343 9.91181C1.07295 11.2179 1.03845 12.6247 1.03845 13.8411V48.1347Z",oD={width:36,height:50},aD={width:50,height:50};function s_(e,t,n){return X("path",{d:e,strokeWidth:2,transform:`translate(${t.x}, ${t.y})`,...n})}const Cr=5;function Js(e,t){this._styles=t,e.registerProvider(this)}Js.$inject=["outline","styles"],Js.prototype.getOutline=function(e){const t=this._styles.cls("djs-outline",["no-fill"]);var n;if(!ge(e))return E(e,"bpmn:Gateway")?(n=X("rect"),D(n.style,{"transform-box":"fill-box",transform:"rotate(45deg)","transform-origin":"center"}),q(n,D({x:2,y:2,rx:4,width:e.width-4,height:e.height-4},t))):ue(e,["bpmn:Task","bpmn:SubProcess","bpmn:Group","bpmn:CallActivity"])?(n=X("rect"),q(n,D({x:-5,y:-5,rx:14,width:e.width+Cr*2,height:e.height+Cr*2},t))):E(e,"bpmn:EndEvent")?(n=X("circle"),q(n,D({cx:e.width/2,cy:e.height/2,r:e.width/2+Cr+1},t))):E(e,"bpmn:Event")?(n=X("circle"),q(n,D({cx:e.width/2,cy:e.height/2,r:e.width/2+Cr},t))):E(e,"bpmn:DataObjectReference")&&c_(e,"bpmn:DataObjectReference")?n=s_(iD,{x:-6,y:-6},t):E(e,"bpmn:DataStoreReference")&&c_(e,"bpmn:DataStoreReference")&&(n=s_(rD,{x:-6,y:-6},t)),n},Js.prototype.updateOutline=function(e,t){if(!ge(e))return ue(e,["bpmn:SubProcess","bpmn:Group"])?(q(t,{width:e.width+Cr*2,height:e.height+Cr*2}),!0):!!ue(e,["bpmn:Event","bpmn:Gateway","bpmn:DataStoreReference","bpmn:DataObjectReference"])};function c_(e,t){var n;return t==="bpmn:DataObjectReference"?n=oD:t==="bpmn:DataStoreReference"&&(n=aD),e.width===n.width&&e.height===n.height}const sD={__depends__:[Nv],__init__:["outlineProvider"],outlineProvider:["type",Js]};var cD='<?xml version="1.0" encoding="UTF-8"?><bpmn:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 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" targetNamespace="http://bpmn.io/schema/bpmn" id="Definitions_1"><bpmn:process id="Process_1" isExecutable="false"><bpmn:startEvent id="StartEvent_1"/></bpmn:process><bpmndi:BPMNDiagram id="BPMNDiagram_1"><bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Process_1"><bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1"><dc:Bounds height="36.0" width="36.0" x="173.0" y="102.0"/></bpmndi:BPMNShape></bpmndi:BPMNPlane></bpmndi:BPMNDiagram></bpmn:definitions>';function an(e){zr.call(this,e)}Y(an,zr),an.Viewer=Zn,an.NavigatedViewer=Zr,an.prototype.createDiagram=function(){return this.importXML(cD)},an.prototype._interactionModules=[eh,rh,sh],an.prototype._modelingModules=[sR,Rl,kR,SR,XR,Ll,nT,l2,ny,Es,d2,g2,M2,N2,O2,j2,Z2,Yy,rM,mM,CM,TM,Tv,JM,nD,sD],an.prototype._modules=[].concat(Zn.prototype._modules,an.prototype._interactionModules,an.prototype._modelingModules);const lD={name:"Camunda",uri:"http://camunda.org/schema/1.0/bpmn",prefix:"camunda",xml:{tagAlias:"lowerCase"},associations:[],types:JSON.parse('[{"name":"Definitions","isAbstract":true,"extends":["bpmn:Definitions"],"properties":[{"name":"diagramRelationId","isAttr":true,"type":"String"}]},{"name":"InOutBinding","superClass":["Element"],"isAbstract":true,"properties":[{"name":"source","isAttr":true,"type":"String"},{"name":"sourceExpression","isAttr":true,"type":"String"},{"name":"target","isAttr":true,"type":"String"},{"name":"businessKey","isAttr":true,"type":"String"},{"name":"local","isAttr":true,"type":"Boolean","default":false},{"name":"variables","isAttr":true,"type":"String"}]},{"name":"In","superClass":["InOutBinding"],"meta":{"allowedIn":["bpmn:CallActivity","bpmn:SignalEventDefinition"]}},{"name":"Out","superClass":["InOutBinding"],"meta":{"allowedIn":["bpmn:CallActivity"]}},{"name":"AsyncCapable","isAbstract":true,"extends":["bpmn:Activity","bpmn:Gateway","bpmn:Event"],"properties":[{"name":"async","isAttr":true,"type":"Boolean","default":false},{"name":"asyncBefore","isAttr":true,"type":"Boolean","default":false},{"name":"asyncAfter","isAttr":true,"type":"Boolean","default":false},{"name":"exclusive","isAttr":true,"type":"Boolean","default":true}]},{"name":"JobPriorized","isAbstract":true,"extends":["bpmn:Process","camunda:AsyncCapable"],"properties":[{"name":"jobPriority","isAttr":true,"type":"String"}]},{"name":"SignalEventDefinitionExtension","isAbstract":true,"extends":["bpmn:SignalEventDefinition"],"properties":[{"name":"async","isAttr":true,"type":"Boolean","default":false}]},{"name":"ErrorEventDefinitionExtension","isAbstract":true,"extends":["bpmn:ErrorEventDefinition"],"properties":[{"name":"errorCodeVariable","isAttr":true,"type":"String"},{"name":"errorMessageVariable","isAttr":true,"type":"String"}]},{"name":"ErrorEventDefinition","superClass":["bpmn:ErrorEventDefinition","Element"],"properties":[{"name":"expression","isAttr":true,"type":"String"}],"meta":{"allowedIn":["bpmn:ServiceTask"]}},{"name":"Error","isAbstract":true,"extends":["bpmn:Error"],"properties":[{"name":"camunda:errorMessage","isAttr":true,"type":"String"}]},{"name":"PotentialStarter","superClass":["Element"],"properties":[{"name":"resourceAssignmentExpression","type":"bpmn:ResourceAssignmentExpression"}]},{"name":"FormSupported","isAbstract":true,"extends":["bpmn:StartEvent","bpmn:UserTask"],"properties":[{"name":"formHandlerClass","isAttr":true,"type":"String"},{"name":"formKey","isAttr":true,"type":"String"},{"name":"formRef","isAttr":true,"type":"String"},{"name":"formRefBinding","isAttr":true,"type":"String"},{"name":"formRefVersion","isAttr":true,"type":"String"}]},{"name":"TemplateSupported","isAbstract":true,"extends":["bpmn:Collaboration","bpmn:Process","bpmn:FlowElement"],"properties":[{"name":"modelerTemplate","isAttr":true,"type":"String"},{"name":"modelerTemplateVersion","isAttr":true,"type":"Integer"}]},{"name":"Initiator","isAbstract":true,"extends":["bpmn:StartEvent"],"properties":[{"name":"initiator","isAttr":true,"type":"String"}]},{"name":"ScriptTask","isAbstract":true,"extends":["bpmn:ScriptTask"],"properties":[{"name":"resultVariable","isAttr":true,"type":"String"},{"name":"resource","isAttr":true,"type":"String"}]},{"name":"Process","isAbstract":true,"extends":["bpmn:Process"],"properties":[{"name":"candidateStarterGroups","isAttr":true,"type":"String"},{"name":"candidateStarterUsers","isAttr":true,"type":"String"},{"name":"versionTag","isAttr":true,"type":"String"},{"name":"historyTimeToLive","isAttr":true,"type":"String"},{"name":"isStartableInTasklist","isAttr":true,"type":"Boolean","default":true}]},{"name":"EscalationEventDefinitionExtension","isAbstract":true,"extends":["bpmn:EscalationEventDefinition"],"properties":[{"name":"escalationCodeVariable","isAttr":true,"type":"String"}]},{"name":"FormalExpression","isAbstract":true,"extends":["bpmn:FormalExpression"],"properties":[{"name":"resource","isAttr":true,"type":"String"}]},{"name":"Assignable","extends":["bpmn:UserTask"],"properties":[{"name":"assignee","isAttr":true,"type":"String"},{"name":"candidateUsers","isAttr":true,"type":"String"},{"name":"candidateGroups","isAttr":true,"type":"String"},{"name":"dueDate","isAttr":true,"type":"String"},{"name":"followUpDate","isAttr":true,"type":"String"},{"name":"priority","isAttr":true,"type":"String"}]},{"name":"CallActivity","extends":["bpmn:CallActivity"],"properties":[{"name":"calledElementBinding","isAttr":true,"type":"String","default":"latest"},{"name":"calledElementVersion","isAttr":true,"type":"String"},{"name":"calledElementVersionTag","isAttr":true,"type":"String"},{"name":"calledElementTenantId","isAttr":true,"type":"String"},{"name":"caseRef","isAttr":true,"type":"String"},{"name":"caseBinding","isAttr":true,"type":"String","default":"latest"},{"name":"caseVersion","isAttr":true,"type":"String"},{"name":"caseTenantId","isAttr":true,"type":"String"},{"name":"variableMappingClass","isAttr":true,"type":"String"},{"name":"variableMappingDelegateExpression","isAttr":true,"type":"String"}]},{"name":"ServiceTaskLike","extends":["bpmn:ServiceTask","bpmn:BusinessRuleTask","bpmn:SendTask","bpmn:MessageEventDefinition"],"properties":[{"name":"expression","isAttr":true,"type":"String"},{"name":"class","isAttr":true,"type":"String"},{"name":"delegateExpression","isAttr":true,"type":"String"},{"name":"resultVariable","isAttr":true,"type":"String"}]},{"name":"DmnCapable","extends":["bpmn:BusinessRuleTask"],"properties":[{"name":"decisionRef","isAttr":true,"type":"String"},{"name":"decisionRefBinding","isAttr":true,"type":"String","default":"latest"},{"name":"decisionRefVersion","isAttr":true,"type":"String"},{"name":"mapDecisionResult","isAttr":true,"type":"String","default":"resultList"},{"name":"decisionRefTenantId","isAttr":true,"type":"String"}]},{"name":"ExternalCapable","extends":["camunda:ServiceTaskLike"],"properties":[{"name":"type","isAttr":true,"type":"String"},{"name":"topic","isAttr":true,"type":"String"}]},{"name":"TaskPriorized","extends":["bpmn:Process","camunda:ExternalCapable"],"properties":[{"name":"taskPriority","isAttr":true,"type":"String"}]},{"name":"Properties","superClass":["Element"],"meta":{"allowedIn":["*"]},"properties":[{"name":"values","type":"Property","isMany":true}]},{"name":"Property","superClass":["Element"],"properties":[{"name":"id","type":"String","isAttr":true},{"name":"name","type":"String","isAttr":true},{"name":"value","type":"String","isAttr":true}]},{"name":"Connector","superClass":["Element"],"meta":{"allowedIn":["camunda:ServiceTaskLike"]},"properties":[{"name":"inputOutput","type":"InputOutput"},{"name":"connectorId","type":"String"}]},{"name":"InputOutput","superClass":["Element"],"meta":{"allowedIn":["bpmn:FlowNode","camunda:Connector"]},"properties":[{"name":"inputOutput","type":"InputOutput"},{"name":"connectorId","type":"String"},{"name":"inputParameters","isMany":true,"type":"InputParameter"},{"name":"outputParameters","isMany":true,"type":"OutputParameter"}]},{"name":"InputOutputParameter","properties":[{"name":"name","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"},{"name":"definition","type":"InputOutputParameterDefinition"}]},{"name":"InputOutputParameterDefinition","isAbstract":true},{"name":"List","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"items","isMany":true,"type":"InputOutputParameterDefinition"}]},{"name":"Map","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"entries","isMany":true,"type":"Entry"}]},{"name":"Entry","properties":[{"name":"key","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"},{"name":"definition","type":"InputOutputParameterDefinition"}]},{"name":"Value","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"id","isAttr":true,"type":"String"},{"name":"name","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"}]},{"name":"Script","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"scriptFormat","isAttr":true,"type":"String"},{"name":"resource","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"}]},{"name":"Field","superClass":["Element"],"meta":{"allowedIn":["camunda:ServiceTaskLike","camunda:ExecutionListener","camunda:TaskListener"]},"properties":[{"name":"name","isAttr":true,"type":"String"},{"name":"expression","type":"String"},{"name":"stringValue","isAttr":true,"type":"String"},{"name":"string","type":"String"}]},{"name":"InputParameter","superClass":["InputOutputParameter"]},{"name":"OutputParameter","superClass":["InputOutputParameter"]},{"name":"Collectable","isAbstract":true,"extends":["bpmn:MultiInstanceLoopCharacteristics"],"superClass":["camunda:AsyncCapable"],"properties":[{"name":"collection","isAttr":true,"type":"String"},{"name":"elementVariable","isAttr":true,"type":"String"}]},{"name":"FailedJobRetryTimeCycle","superClass":["Element"],"meta":{"allowedIn":["camunda:AsyncCapable","bpmn:MultiInstanceLoopCharacteristics"]},"properties":[{"name":"body","isBody":true,"type":"String"}]},{"name":"ExecutionListener","superClass":["Element"],"meta":{"allowedIn":["bpmn:Task","bpmn:ServiceTask","bpmn:UserTask","bpmn:BusinessRuleTask","bpmn:ScriptTask","bpmn:ReceiveTask","bpmn:ManualTask","bpmn:ExclusiveGateway","bpmn:SequenceFlow","bpmn:ParallelGateway","bpmn:InclusiveGateway","bpmn:EventBasedGateway","bpmn:StartEvent","bpmn:IntermediateCatchEvent","bpmn:IntermediateThrowEvent","bpmn:EndEvent","bpmn:BoundaryEvent","bpmn:CallActivity","bpmn:SubProcess","bpmn:Process"]},"properties":[{"name":"expression","isAttr":true,"type":"String"},{"name":"class","isAttr":true,"type":"String"},{"name":"delegateExpression","isAttr":true,"type":"String"},{"name":"event","isAttr":true,"type":"String"},{"name":"script","type":"Script"},{"name":"fields","type":"Field","isMany":true}]},{"name":"TaskListener","superClass":["Element"],"meta":{"allowedIn":["bpmn:UserTask"]},"properties":[{"name":"expression","isAttr":true,"type":"String"},{"name":"class","isAttr":true,"type":"String"},{"name":"delegateExpression","isAttr":true,"type":"String"},{"name":"event","isAttr":true,"type":"String"},{"name":"script","type":"Script"},{"name":"fields","type":"Field","isMany":true},{"name":"id","type":"String","isAttr":true},{"name":"eventDefinitions","type":"bpmn:TimerEventDefinition","isMany":true}]},{"name":"FormProperty","superClass":["Element"],"meta":{"allowedIn":["bpmn:StartEvent","bpmn:UserTask"]},"properties":[{"name":"id","type":"String","isAttr":true},{"name":"name","type":"String","isAttr":true},{"name":"type","type":"String","isAttr":true},{"name":"required","type":"String","isAttr":true},{"name":"readable","type":"String","isAttr":true},{"name":"writable","type":"String","isAttr":true},{"name":"variable","type":"String","isAttr":true},{"name":"expression","type":"String","isAttr":true},{"name":"datePattern","type":"String","isAttr":true},{"name":"default","type":"String","isAttr":true},{"name":"values","type":"Value","isMany":true}]},{"name":"FormData","superClass":["Element"],"meta":{"allowedIn":["bpmn:StartEvent","bpmn:UserTask"]},"properties":[{"name":"fields","type":"FormField","isMany":true},{"name":"businessKey","type":"String","isAttr":true}]},{"name":"FormField","superClass":["Element"],"properties":[{"name":"id","type":"String","isAttr":true},{"name":"label","type":"String","isAttr":true},{"name":"type","type":"String","isAttr":true},{"name":"datePattern","type":"String","isAttr":true},{"name":"defaultValue","type":"String","isAttr":true},{"name":"properties","type":"Properties"},{"name":"validation","type":"Validation"},{"name":"values","type":"Value","isMany":true}]},{"name":"Validation","superClass":["Element"],"properties":[{"name":"constraints","type":"Constraint","isMany":true}]},{"name":"Constraint","superClass":["Element"],"properties":[{"name":"name","type":"String","isAttr":true},{"name":"config","type":"String","isAttr":true}]},{"name":"ConditionalEventDefinitionExtension","isAbstract":true,"extends":["bpmn:ConditionalEventDefinition"],"properties":[{"name":"variableName","isAttr":true,"type":"String"},{"name":"variableEvents","isAttr":true,"type":"String"}]}]'),emumerations:[]},uD=bn(f.defineComponent({inheritAttrs:!1,__name:"index",props:f.mergeModels({dictType:{type:String,default:""},include:{type:[Array,String]},exclude:{type:Array},sort:{type:Boolean}},{dictMap:{type:Object},dictMapModifiers:{}}),emits:["update:dictMap"],setup(e){const t=e,n=f.useModel(e,"dictMap"),[i,{fetchDict:r,toList:o}]=Sp(t.dictType,{immediate:!1}),a=f.computed(()=>{var c;const s=o(t.dictType);if(t.sort&&s.sort((l,u)=>parseFloat(l.value)-parseFloat(u.value)),t.include){const l=typeof t.include=="string"?t.include.split(","):t.include;return s.filter(u=>l.includes(u.value))}return(c=t.exclude)!=null&&c.length?s.filter(l=>{var u;return!((u=t.exclude)!=null&&u.includes(l.value))}):s});return t.dictType&&r(),f.watch(()=>i.value,()=>{if(n.value&&typeof n.value=="object")for(const s in i.value)n.value[s]=i.value}),(s,c)=>{const l=U.Select;return f.openBlock(),f.createBlock(l,f.mergeProps({class:"dict-select",placeholder:s.$t("common.plsSelect"),showSearch:!1,options:f.unref(a),dropdownMatchSelectWidth:!1},s.$attrs),null,16,["placeholder","options"])}}}),[["__scopeId","data-v-02a7899b"]]),pD={class:"icon",viewBox:"0 0 1024 1024",width:"1.2em",height:"1.2em"};function fD(e,t){return f.openBlock(),f.createElementBlock("svg",pD,t[0]||(t[0]=[f.createElementVNode("path",{fill:"currentColor",d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448s448-200.6 448-448S759.4 64 512 64m0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372s372 166.6 372 372s-166.6 372-372 372"},null,-1),f.createElementVNode("path",{fill:"currentColor",d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7c-21.2 8.1-39.2 22.3-52.1 40.9c-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0 1 30.9-44.8c59-22.7 97.1-74.7 97.1-132.5c.1-39.3-17.1-76-48.3-103.3M472 732a40 40 0 1 0 80 0a40 40 0 1 0-80 0"},null,-1)]))}const dD=f.markRaw({name:"ant-design-question-circle",render:fD}),hD={class:"wrapper"},mD={class:"mt-xs"},gD={class:"flex-sc"},yD={class:"mt-xs"},vD={class:"mr-xs"},_D=bn(f.defineComponent({__name:"RuleConfig",props:{jsonStr:{type:String,required:!0}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({});function a(p){const d=p.replace(/(false|true|\d+)(?=")/g,"$1,");return JSON.parse(`{${d}}`)}function s(p){if(typeof p=="string"&&(p.trim().startsWith("{")||p.trim().startsWith("[")))try{return JSON.parse(p),!0}catch{return!1}return!1}function c(){i.jsonStr?(s(i.jsonStr)?o.value=JSON.parse(i.jsonStr):o.value=a(i.jsonStr),o.value.fallbackFirstLinkStatus!==null&&o.value.fallbackFirstLinkStatus!==void 0&&(o.value.fallbackFirstLinkStatus=String(o.value.fallbackFirstLinkStatus))):o.value={revokeRule:!1,fallbackRule:!1,approverRemoveDuplicates:2,timeoutConfigSwitch:!1,timeoutPeriod:1,timeoutHandler:1,fallbackFirstLinkStatus:null}}function l(){Qe.Modal.destroyAll()}function u(){const p=o.value;if(p.timeoutConfigSwitch&&!p.timeoutPeriod){Qe.message.warning(n("bpmn.timeoutPeriodEmptyTip"));return}p.fallbackFirstLinkStatus&&(p.fallbackFirstLinkStatus=Number(p.fallbackFirstLinkStatus)),r("submit",o.value),Qe.Modal.destroyAll()}return f.onMounted(()=>{c()}),(p,d)=>{const h=U.Checkbox,m=U.FormItem,y=U.Radio,g=U.RadioGroup,w=U.InputNumber,C=dD,x=U.Tooltip,b=uD,S=U.Form,P=U.Button,M=U.Space;return f.openBlock(),f.createElementBlock("div",hD,[f.createVNode(S,{class:"my-nm","label-col":{span:6},"wrapper-col":{span:18},colon:!1,model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(m,{label:p.$t("bpmn.revertRule")},{default:f.withCtx(()=>[f.createVNode(h,{checked:f.unref(o).revokeRule,"onUpdate:checked":d[0]||(d[0]=R=>f.unref(o).revokeRule=R)},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.revertRuleTxt")),1)]),_:1},8,["checked"])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.rollbackRule")},{default:f.withCtx(()=>[f.createVNode(h,{checked:f.unref(o).fallbackRule,"onUpdate:checked":d[1]||(d[1]=R=>f.unref(o).fallbackRule=R)},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.rollbackRuleTxt")),1)]),_:1},8,["checked"])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.deduplicationApprovers")},{default:f.withCtx(()=>[f.createElementVNode("div",mD,f.toDisplayString(p.$t("bpmn.deduplicationApproversTxt")),1),f.createVNode(g,{value:f.unref(o).approverRemoveDuplicates,"onUpdate:value":d[2]||(d[2]=R=>f.unref(o).approverRemoveDuplicates=R)},{default:f.withCtx(()=>[f.createVNode(y,{value:0},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.deduplicationRadio0")),1)]),_:1}),f.createVNode(y,{value:1},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.deduplicationRadio1")),1)]),_:1}),f.createVNode(y,{value:2},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.deduplicationRadio2")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.timeoutRule")},{default:f.withCtx(()=>[f.createVNode(h,{checked:f.unref(o).timeoutConfigSwitch,"onUpdate:checked":d[3]||(d[3]=R=>f.unref(o).timeoutConfigSwitch=R)},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.timeoutRuleTxt")),1)]),_:1},8,["checked"])]),_:1},8,["label"]),f.unref(o).timeoutConfigSwitch?(f.openBlock(),f.createElementBlock(f.Fragment,{key:0},[f.createVNode(m,{label:p.$t("wo_my.timeout")},{default:f.withCtx(()=>[f.createElementVNode("div",gD,[f.createTextVNode(f.toDisplayString(p.$t("bpmn.linkTimeoutTxt1"))+" ",1),f.createVNode(w,{class:"mx-xs",value:f.unref(o).timeoutPeriod,"onUpdate:value":d[4]||(d[4]=R=>f.unref(o).timeoutPeriod=R),min:1,max:1e4,precision:0},null,8,["value"]),f.createTextVNode(" "+f.toDisplayString(p.$t("bpmn.linkTimeoutTxt2")),1)])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.timeoutHandle")},{default:f.withCtx(()=>[f.createElementVNode("div",yD,f.toDisplayString(p.$t("bpmn.timeoutHandleTxt")),1),f.createVNode(g,{value:f.unref(o).timeoutHandler,"onUpdate:value":d[5]||(d[5]=R=>f.unref(o).timeoutHandler=R)},{default:f.withCtx(()=>[f.createVNode(y,{value:0},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.timeoutHandleRadio0")),1)]),_:1}),f.createVNode(y,{value:1},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.timeoutHandleRadio1")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["label"])],64)):f.createCommentVNode("",!0),f.createVNode(m,null,{label:f.withCtx(()=>[f.createElementVNode("span",vD,f.toDisplayString(p.$t("bpmn.fallbackFirstLinkStatus")),1),f.createVNode(x,{overlayInnerStyle:{width:"600px"}},{title:f.withCtx(()=>[f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip1")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip2")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip3")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip4")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip5")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip6")),1)]),default:f.withCtx(()=>[f.createVNode(C)]),_:1})]),default:f.withCtx(()=>[f.createVNode(b,{"dict-type":"fallback_first_link_status",value:f.unref(o).fallbackFirstLinkStatus,"onUpdate:value":d[6]||(d[6]=R=>f.unref(o).fallbackFirstLinkStatus=R),placeholder:p.$t("common.plsSelect"),style:{width:"80%"}},null,8,["value","placeholder"])]),_:1})]),_:1},8,["model"]),f.createVNode(M,{class:"modal-btns"},{default:f.withCtx(()=>[f.createVNode(P,{onClick:l},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(P,{type:"primary",onClick:u},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("common.btn_sure")),1)]),_:1})]),_:1})])}}}),[["__scopeId","data-v-584e9946"]]),bD=f.defineComponent({__name:"Process",props:f.mergeModels({isEdit:{type:Boolean}},{formState:{},formStateModifiers:{}}),emits:["update:formState"],setup(e){const{modal:t}=Qe.App.useApp(),{t:n}=Zt.useI18n(),i=f.useModel(e,"formState"),r=f.ref(["1","2","3","4","5","6"]);function o(){t.info({title:n("ruleModel.title"),content:f.h(_D,{jsonStr:i.value.jobPriority,onSubmit:a=>{i.value.jobPriority=JSON.stringify(a)}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:850,class:"modal-comp"})}return(a,s)=>{const c=U.Input,l=U.FormItem,u=U.Form,p=U.CollapsePanel,d=U.Collapse;return f.openBlock(),f.createBlock(d,{activeKey:f.unref(r),"onUpdate:activeKey":s[4]||(s[4]=h=>f.isRef(r)?r.value=h:null)},{default:f.withCtx(()=>[f.createVNode(p,{key:"1",header:a.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(u,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(l,{label:a.$t("FLOW_CHART.Id"),extra:a.$t("FLOW_CHART.idTip")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.id,"onUpdate:value":s[0]||(s[0]=h=>i.value.id=h),placeholder:a.$t("common.plsEnter"),readonly:e.isEdit},null,8,["value","placeholder","readonly"])]),_:1},8,["label","extra"]),f.createVNode(l,{label:a.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.name,"onUpdate:value":s[1]||(s[1]=h=>i.value.name=h),placeholder:a.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(l,{label:a.$t("FLOW_CHART.Version Tag")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.versionTag,"onUpdate:value":s[2]||(s[2]=h=>i.value.versionTag=h),disabled:""},null,8,["value"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"]),f.createVNode(p,{key:"4",header:a.$t("FLOW_CHART.Job Configuration")},{default:f.withCtx(()=>[f.createVNode(u,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(l,{label:a.$t("FLOW_CHART.Job Priority")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.jobPriority,"onUpdate:value":s[3]||(s[3]=h=>i.value.jobPriority=h),placeholder:a.$t("common.plsSelect"),readonly:"",onClick:o},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),ED=bn(f.defineComponent({__name:"TemplateConfig",props:{data:{type:Object,default:()=>{}},templateList:{type:Array,default:()=>[]}},emits:["update:data"],setup(e,{emit:t}){const n=t,i=e,r=f.computed({get:()=>i.data,set:l=>{n("update:data",l)}}),o=f.computed(()=>i.templateList.filter(l=>{var u;return(u=l==null?void 0:l.type)==null?void 0:u.split(",").includes("1")}).map(l=>({label:l.name,value:l.id}))),a=f.computed(()=>i.templateList.filter(l=>{var u;return(u=l==null?void 0:l.type)==null?void 0:u.split(",").includes("2")}).map(l=>({label:l.name,value:l.id}))),s=f.computed(()=>i.templateList.filter(l=>{var u;return(u=l==null?void 0:l.type)==null?void 0:u.split(",").includes("3")}).map(l=>({label:l.name,value:l.id}))),c=(l,u)=>u.label.toLowerCase().indexOf(l.toLowerCase())>=0;return(l,u)=>{const p=U.Select,d=U.FormItem,h=U.Form;return f.openBlock(),f.createElementBlock("div",null,[f.createVNode(h,{class:"form-query-select mx-nm mt-nm",layout:"vertical",model:r.value},{default:f.withCtx(()=>[f.createVNode(d,{label:l.$t("待办工单处理")},{default:f.withCtx(()=>[f.createVNode(p,{value:r.value[1],"onUpdate:value":u[0]||(u[0]=m=>r.value[1]=m),options:o.value,allowClear:"",placeholder:l.$t("common.plsSelect"),"show-search":"","filter-option":c},null,8,["value","options","placeholder"])]),_:1},8,["label"]),f.createVNode(d,{label:l.$t("待办工单详情")},{default:f.withCtx(()=>[f.createVNode(p,{value:r.value[2],"onUpdate:value":u[1]||(u[1]=m=>r.value[2]=m),options:a.value,allowClear:"",placeholder:l.$t("common.plsSelect"),"show-search":"","filter-option":c},null,8,["value","options","placeholder"])]),_:1},8,["label"]),f.createVNode(d,{label:l.$t("全部工单详情")},{default:f.withCtx(()=>[f.createVNode(p,{value:r.value[3],"onUpdate:value":u[2]||(u[2]=m=>r.value[3]=m),options:s.value,allowClear:"",placeholder:l.$t("common.plsSelect"),"show-search":"","filter-option":c},null,8,["value","options","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])])}}}),[["__scopeId","data-v-5c46da3d"]]),xD={class:"modal-container"},wD=f.defineComponent({__name:"SelectLinkTask",props:{id:{type:String},componentInfo:{type:String,default:""},variable:{type:String,default:""},description:{type:String,default:""}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({}),a=f.ref([{title:n("link.id"),dataIndex:"id"},{title:n("link.description"),dataIndex:"description"},{title:n("link.due"),dataIndex:"due"},{title:n("link.variable"),dataIndex:"variable"},{title:n("bpmn.action"),dataIndex:"action"}]),s=f.ref([]),c=f.ref();function l(O,F){s.value=O,c.value=F}const u=f.ref({1:void 0,2:void 0,3:void 0}),p=f.ref({}),d=f.ref(!1),h=f.ref(""),m=f.ref("");function y(){d.value=!1,h.value=JSON.stringify(u.value)}function g(){d.value=!1}function w(O){p.value=O,d.value=!0}const C=f.ref([]);async function x(){const{result:O}=await ct.getTemplateList({pageNo:1,pageSize:1e3});C.value=(O==null?void 0:O.data)||[]}const b=f.ref([]);async function S(){const{result:O}=await ct.getLinkList({pageNo:1,pageSize:1e3});b.value=(O==null?void 0:O.data)||[]}f.watchEffect(()=>{i.id&&(i.id.startsWith("common-approve-")||i.id.startsWith("common-handle-")?(m.value=i.id.slice(-4),s.value=[i.id.slice(0,-4)+"*"]):s.value=[i.id]),i.componentInfo&&(u.value=JSON.parse(i.componentInfo)||{})});function P(O){c.value=null;const F={...o.value};return Object.assign(F,O),ct.getLinkList(F)}const M=f.ref(),R=()=>{M.value.refresh()},I=()=>{o.value={},R()};f.onMounted(()=>{I(),x(),S()});function B(){Qe.Modal.destroyAll()}function L(){var O,F;if((O=c.value)!=null&&O.length)r("submit",{...c.value[0],bindComponent:h.value,hasSuffix:""});else if((F=s.value)!=null&&F.length){const G=b.value.find(ke=>ke.id===s.value[0]);r("submit",{...G,id:i.id,bindComponent:h.value,hasSuffix:m.value})}Qe.Modal.destroyAll()}return(O,F)=>{const G=U.Input,ke=U.FormItem,be=U.Button,ce=U.Space,st=U.Form,We=U.Tooltip,Ee=f.resolveComponent("a-table-ex"),Te=U.Modal;return f.openBlock(),f.createElementBlock(f.Fragment,null,[f.createElementVNode("div",xD,[f.createVNode(st,{class:"form-query mx-nm mt-nm",layout:"vertical",model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(ke,{label:O.$t("link.id")},{default:f.withCtx(()=>[f.createVNode(G,{value:f.unref(o).id,"onUpdate:value":F[0]||(F[0]=$=>f.unref(o).id=$),placeholder:O.$t("common.plsEnter"),onKeydown:f.withKeys(R,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(ke,{label:O.$t("link.description")},{default:f.withCtx(()=>[f.createVNode(G,{value:f.unref(o).description,"onUpdate:value":F[1]||(F[1]=$=>f.unref(o).description=$),placeholder:O.$t("common.plsEnter"),onKeydown:f.withKeys(R,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(ke,{class:"form-btns"},{default:f.withCtx(()=>[f.createVNode(ce,null,{default:f.withCtx(()=>[f.createVNode(be,{type:"primary",onClick:R},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_search")),1)]),_:1}),f.createVNode(be,{onClick:I},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_reset")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),f.createVNode(Ee,{ref_key:"tableEx",ref:M,class:"table-query bordered mx-nm",columns:f.unref(a),rowKey:"id","row-selection":{type:"radio",selectedRowKeys:f.unref(s),onChange:l},loadData:P},{bodyCell:f.withCtx(({record:$,column:H})=>[H.dataIndex==="action"?(f.openBlock(),f.createBlock(We,{key:0,placement:"top"},{title:f.withCtx(()=>[f.createElementVNode("span",null,f.toDisplayString(O.$t("bpmn.tempConfigTip")),1)]),default:f.withCtx(()=>[f.createVNode(be,{type:"link",onClick:Z=>w($),style:{"padding-left":"0"},disabled:!f.unref(s).includes($.id)},{default:f.withCtx(()=>F[4]||(F[4]=[f.createTextVNode(f.toDisplayString("配置渲染模版"))])),_:2},1032,["onClick","disabled"])]),_:2},1024)):f.createCommentVNode("",!0)]),_:1},8,["columns","row-selection"]),f.createVNode(ce,{class:"modal-btns"},{default:f.withCtx(()=>{var $;return[f.createVNode(be,{onClick:B},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(be,{type:"primary",disabled:!(($=f.unref(s))!=null&&$.length),onClick:L},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_sure")),1)]),_:1},8,["disabled"])]}),_:1})]),f.createVNode(Te,{open:f.unref(d),"onUpdate:open":F[3]||(F[3]=$=>f.isRef(d)?d.value=$:null),title:"配置渲染模版",onOk:y,onCancel:g},{default:f.withCtx(()=>[f.createVNode(ED,{data:f.unref(u),"onUpdate:data":F[2]||(F[2]=$=>f.isRef(u)?u.value=$:null),"template-list":f.unref(C)},null,8,["data","template-list"])]),_:1},8,["open"])],64)}}}),SD={class:"modal-container"},CD=f.defineComponent({__name:"SelectUser",props:{userIds:{type:String||Array},branchId:{type:String},mode:{type:String,default:"default"}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({}),a=f.ref([{title:n("user.user_name"),dataIndex:"userName"},{title:n("user.user_id"),dataIndex:"userCode"},{title:n("arrears.org"),dataIndex:"branchName"}]),s=f.ref([]),c=f.ref();function l(g,w){s.value=g,c.value=w}f.watchEffect(()=>{i.userIds&&(s.value=Array.isArray(i.userIds)?i.userIds:[i.userIds])});function u(g){c.value=null;const w={...o.value,branchId:i.branchId};return Object.assign(w,g),ct.getUserList(w)}const p=f.ref(),d=()=>{p.value.refresh()},h=()=>{o.value={},d()};f.onMounted(()=>{h()});function m(){Qe.Modal.destroyAll()}function y(){var g;if((g=c.value)!=null&&g.length){const w=c.value;r("submit",i.mode==="multiple"?w:w[0])}Qe.Modal.destroyAll()}return(g,w)=>{const C=U.Input,x=U.FormItem,b=U.Button,S=U.Space,P=U.Form,M=f.resolveComponent("a-table-ex");return f.openBlock(),f.createElementBlock("div",SD,[f.createVNode(P,{class:"form-query mx-nm mt-nm",layout:"vertical",model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(x,{label:g.$t("user.key")},{default:f.withCtx(()=>[f.createVNode(C,{value:f.unref(o).userName,"onUpdate:value":w[0]||(w[0]=R=>f.unref(o).userName=R),placeholder:g.$t("common.plsEnter"),onKeydown:f.withKeys(d,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(x,{class:"form-btns"},{default:f.withCtx(()=>[f.createVNode(S,null,{default:f.withCtx(()=>[f.createVNode(b,{type:"primary",onClick:d},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_search")),1)]),_:1}),f.createVNode(b,{onClick:h},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_reset")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),f.createVNode(M,{ref_key:"tableEx",ref:p,class:"table-query bordered mx-nm",columns:f.unref(a),rowKey:"userId","row-selection":{type:e.mode==="multiple"?"checkbox":"radio",selectedRowKeys:f.unref(s),onChange:l},loadData:u},null,8,["columns","row-selection"]),f.createVNode(S,{class:"modal-btns"},{default:f.withCtx(()=>{var R;return[f.createVNode(b,{onClick:m},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(b,{type:"primary",disabled:!((R=f.unref(s))!=null&&R.length),onClick:y},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_sure")),1)]),_:1},8,["disabled"])]}),_:1})])}}}),RD=f.defineComponent({__name:"UserTask",props:f.mergeModels({isApproval:{type:Boolean}},{formState:{},formStateModifiers:{}}),emits:["update:formState"],setup(e){const{modal:t}=Qe.App.useApp(),{t:n}=Zt.useI18n(),i=f.useModel(e,"formState"),r=f.ref(["1","2","3","4","5","6"]),o=f.ref([]),a=f.ref([]),s=f.ref([]),c=f.computed(()=>{const w=i.value.assignee;return w==null?void 0:w.startsWith("${")});function l(){const w="abcdefghijklmnopqrstuvwxyz";let C="";for(let x=0;x<2;x++)C+=w.charAt(Math.floor(Math.random()*w.length));for(let x=0;x<2;x++)C+=Math.floor(Math.random()*10);return C}function u(){t.info({title:n("link.select_link"),content:f.h(wD,{id:i.value.id,variable:i.value.assignee,description:i.value.name,componentInfo:i.value.bindComponent,onSubmit:w=>{let C=w.id;C.endsWith("*")&&(w.hasSuffix?C=C.substring(0,C.length-1)+w.hasSuffix:C=C.substring(0,C.length-1)+l()),Object.assign(i.value,{id:C,name:w.description,assignee:"","camunda:assigneeName":"",priority:void 0,userArr:[],roleArr:[]}),w.variable&&(i.value.assignee=`\${${w.variable}}`),w.bindComponent&&(i.value.bindComponent=w.bindComponent)}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:850,zIndex:100,class:"modal-comp"})}function p(){t.info({title:n("user.select_user"),content:f.h(CD,{userIds:i.value.assignee,onSubmit:w=>{Object.assign(i.value,{assignee:w.userId,"camunda:assigneeName":w.userName})}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:800,class:"modal-comp"})}function d(){ct.getBranchTree().then(w=>{w.code===0&&(o.value=w.result||[])})}function h(){const w={pageNo:1,pageSize:1e3,branchId:i.value.priority||void 0};ct.getUserList(w).then(C=>{var x,b;C.code===0&&(s.value=((b=(x=C.result)==null?void 0:x.data)==null?void 0:b.map(S=>({...S,label:S.userName,value:S.userId})))||[])})}function m(){const w={pageNo:1,pageSize:1e3,branchId:i.value.priority||void 0};ct.getRoleList(w).then(C=>{var x,b;C.code===0&&(a.value=((b=(x=C.result)==null?void 0:x.data)==null?void 0:b.map(S=>({...S,label:S.roleName,value:S.roleId})))||[])})}function y(){Object.assign(i.value,{userArr:[],roleArr:[]}),h(),m()}function g(w){if(w!=null&&w.length){const C=s.value.find(x=>x.userId===w[0]);i.value.priority!==C.branchId&&(Object.assign(i.value,{priority:C.branchId,roleArr:[]}),h(),m())}}return f.onMounted(()=>{d(),h(),m()}),(w,C)=>{const x=U.Input,b=U.FormItem,S=U.TreeSelect,P=U.Select,M=U.Form,R=U.CollapsePanel,I=U.Radio,B=U.RadioGroup,L=U.Checkbox,O=U.CheckboxGroup,F=U.Collapse;return f.openBlock(),f.createBlock(F,{activeKey:f.unref(r),"onUpdate:activeKey":C[10]||(C[10]=G=>f.isRef(r)?r.value=G:null)},{default:f.withCtx(()=>[f.createVNode(R,{key:"1",header:w.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(M,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(b,{label:w.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(x,{value:i.value.id,"onUpdate:value":C[0]||(C[0]=G=>i.value.id=G),placeholder:w.$t("common.plsEnter"),readonly:"",onClick:u},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(x,{value:i.value.name,"onUpdate:value":C[1]||(C[1]=G=>i.value.name=G),placeholder:w.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Assignee")},{default:f.withCtx(()=>[f.unref(c)?(f.openBlock(),f.createBlock(x,{key:0,value:i.value.assignee,"onUpdate:value":C[2]||(C[2]=G=>i.value.assignee=G),placeholder:w.$t("common.plsSelect"),disabled:""},null,8,["value","placeholder"])):(f.openBlock(),f.createBlock(x,{key:1,value:i.value["camunda:assigneeName"],"onUpdate:value":C[3]||(C[3]=G=>i.value["camunda:assigneeName"]=G),placeholder:w.$t("common.plsSelect"),readonly:"",onClick:p},null,8,["value","placeholder"]))]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Priority")},{default:f.withCtx(()=>[f.createVNode(S,{value:i.value.priority,"onUpdate:value":C[4]||(C[4]=G=>i.value.priority=G),placeholder:w.$t("common.plsSelect"),"tree-data":f.unref(o),treeDefaultExpandAll:"",treeNodeFilterProp:"label","show-search":"","allow-clear":"",onChange:y},null,8,["value","placeholder","tree-data"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Candidate Users")},{default:f.withCtx(()=>[f.createVNode(P,{value:i.value.userArr,"onUpdate:value":C[5]||(C[5]=G=>i.value.userArr=G),placeholder:w.$t("common.plsSelect"),mode:"multiple",maxTagCount:10,options:f.unref(s),optionFilterProp:"label",disabled:f.unref(c),onChange:g},null,8,["value","placeholder","options","disabled"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Candidate Groups")},{default:f.withCtx(()=>[f.createVNode(P,{value:i.value.roleArr,"onUpdate:value":C[6]||(C[6]=G=>i.value.roleArr=G),placeholder:w.$t("common.plsSelect"),mode:"multiple",maxTagCount:10,options:f.unref(a),optionFilterProp:"label",disabled:f.unref(c)},null,8,["value","placeholder","options","disabled"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"]),e.isApproval?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(R,{key:"2",header:w.$t("FLOW_CHART.isAllowRollback")},{default:f.withCtx(()=>[f.createVNode(B,{value:i.value.rollback,"onUpdate:value":C[7]||(C[7]=G=>i.value.rollback=G)},{default:f.withCtx(()=>[f.createVNode(I,{value:"1"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.yes")),1)]),_:1}),f.createVNode(I,{value:"0"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.no")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["header"])),e.isApproval?(f.openBlock(),f.createBlock(R,{key:"3",header:w.$t("FLOW_CHART.Approval Mode")},{default:f.withCtx(()=>[f.createVNode(B,{value:i.value.approvalSign,"onUpdate:value":C[8]||(C[8]=G=>i.value.approvalSign=G)},{default:f.withCtx(()=>[f.createVNode(I,{value:"orSign"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.Or Sign")),1)]),_:1}),f.createVNode(I,{value:"countersign"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.countersign")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["header"])):f.createCommentVNode("",!0),e.isApproval?(f.openBlock(),f.createBlock(R,{key:"4",header:w.$t("FLOW_CHART.Approval Required")},{default:f.withCtx(()=>[f.createVNode(O,{value:i.value.approvalCheckbox,"onUpdate:value":C[9]||(C[9]=G=>i.value.approvalCheckbox=G)},{default:f.withCtx(()=>[f.createVNode(L,{value:"advice"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.Comments Required")),1)]),_:1}),f.createVNode(L,{value:"attachment"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.Attachment Required")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["header"])):f.createCommentVNode("",!0)]),_:1},8,["activeKey"])}}}),TD=f.defineComponent({__name:"ExclusiveGateway",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const t=f.useModel(e,"formState"),n=f.ref(["1","2","3","4","5","6"]);return(i,r)=>{const o=U.Input,a=U.FormItem,s=U.Form,c=U.CollapsePanel,l=U.Collapse;return f.openBlock(),f.createBlock(l,{activeKey:f.unref(n),"onUpdate:activeKey":r[2]||(r[2]=u=>f.isRef(n)?n.value=u:null)},{default:f.withCtx(()=>[f.createVNode(c,{key:"1",header:i.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(s,{layout:"vertical",model:t.value},{default:f.withCtx(()=>[f.createVNode(a,{label:i.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.id,"onUpdate:value":r[0]||(r[0]=u=>t.value.id=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.name,"onUpdate:value":r[1]||(r[1]=u=>t.value.name=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),PD=f.defineComponent({__name:"SequenceFlow",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const t=f.useModel(e,"formState"),n=f.ref(["1","2","3","4","5","6"]);return(i,r)=>{const o=U.Input,a=U.FormItem,s=U.SelectOption,c=U.Select,l=U.Form,u=U.CollapsePanel,p=U.Collapse;return f.openBlock(),f.createBlock(p,{activeKey:f.unref(n),"onUpdate:activeKey":r[4]||(r[4]=d=>f.isRef(n)?n.value=d:null)},{default:f.withCtx(()=>[f.createVNode(u,{key:"1",header:i.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(l,{layout:"vertical",model:t.value},{default:f.withCtx(()=>[f.createVNode(a,{label:i.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.id,"onUpdate:value":r[0]||(r[0]=d=>t.value.id=d),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.name,"onUpdate:value":r[1]||(r[1]=d=>t.value.name=d),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Condition Type")},{default:f.withCtx(()=>[f.createVNode(c,{value:t.value.condType,"onUpdate:value":r[2]||(r[2]=d=>t.value.condType=d),placeholder:i.$t("common.plsSelect"),allowClear:""},{default:f.withCtx(()=>[f.createVNode(s,{value:"bpmn:FormalExpression"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(i.$t("FLOW_CHART.Expression")),1)]),_:1})]),_:1},8,["value","placeholder"])]),_:1},8,["label"]),t.value.condType==="bpmn:FormalExpression"?(f.openBlock(),f.createBlock(a,{key:0,label:i.$t("FLOW_CHART.Expression")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.condBody,"onUpdate:value":r[3]||(r[3]=d=>t.value.condBody=d),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])):f.createCommentVNode("",!0)]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),AD={class:"modal-container"},kD=f.defineComponent({__name:"SelectLink",props:{id:{type:String}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({}),a=f.ref([{title:n("link.id"),dataIndex:"id"},{title:n("link.description"),dataIndex:"description"},{title:n("link.due"),dataIndex:"due"},{title:n("link.variable"),dataIndex:"variable"}]),s=f.ref([]),c=f.ref();function l(g,w){s.value=g,c.value=w}f.watchEffect(()=>{i.id&&(s.value=[i.id])});function u(g){c.value=null;const w={...o.value};return Object.assign(w,g),ct.getLinkList(w)}const p=f.ref(),d=()=>{p.value.refresh()},h=()=>{o.value={},d()};f.onMounted(()=>{h()});function m(){Qe.Modal.destroyAll()}function y(){var g;(g=c.value)!=null&&g.length&&r("submit",c.value[0]),Qe.Modal.destroyAll()}return(g,w)=>{const C=U.Input,x=U.FormItem,b=U.Button,S=U.Space,P=U.Form,M=f.resolveComponent("a-table-ex");return f.openBlock(),f.createElementBlock("div",AD,[f.createVNode(P,{class:"form-query mx-nm mt-nm",layout:"vertical",model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(x,{label:g.$t("link.id")},{default:f.withCtx(()=>[f.createVNode(C,{value:f.unref(o).id,"onUpdate:value":w[0]||(w[0]=R=>f.unref(o).id=R),placeholder:g.$t("common.plsEnter"),onKeydown:f.withKeys(d,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(x,{label:g.$t("link.description")},{default:f.withCtx(()=>[f.createVNode(C,{value:f.unref(o).description,"onUpdate:value":w[1]||(w[1]=R=>f.unref(o).description=R),placeholder:g.$t("common.plsEnter"),onKeydown:f.withKeys(d,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(x,{class:"form-btns"},{default:f.withCtx(()=>[f.createVNode(S,null,{default:f.withCtx(()=>[f.createVNode(b,{type:"primary",onClick:d},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_search")),1)]),_:1}),f.createVNode(b,{onClick:h},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_reset")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),f.createVNode(M,{ref_key:"tableEx",ref:p,class:"table-query bordered mx-nm",columns:f.unref(a),rowKey:"id","row-selection":{type:"radio",selectedRowKeys:f.unref(s),onChange:l},loadData:u},null,8,["columns","row-selection"]),f.createVNode(S,{class:"modal-btns"},{default:f.withCtx(()=>{var R;return[f.createVNode(b,{onClick:m},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(b,{type:"primary",disabled:!((R=f.unref(s))!=null&&R.length),onClick:y},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_sure")),1)]),_:1},8,["disabled"])]}),_:1})])}}}),MD=f.defineComponent({__name:"EndEvent",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const{modal:t}=Qe.App.useApp(),{t:n}=Zt.useI18n(),i=f.useModel(e,"formState"),r=f.ref(["1","2","3","4","5","6"]);function o(){const s="abcdefghijklmnopqrstuvwxyz";let c="";for(let l=0;l<2;l++)c+=s.charAt(Math.floor(Math.random()*s.length));for(let l=0;l<2;l++)c+=Math.floor(Math.random()*10);return c}function a(){t.info({title:n("link.select_link"),content:f.h(kD,{id:i.value.id,onSubmit:s=>{let c=s.id;c.endsWith("*")&&(c=c.substring(0,c.length-1)+o()),Object.assign(i.value,{id:c,name:s.description})}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:800,class:"modal-comp"})}return(s,c)=>{const l=U.Input,u=U.FormItem,p=U.Form,d=U.CollapsePanel,h=U.Collapse;return f.openBlock(),f.createBlock(h,{activeKey:f.unref(r),"onUpdate:activeKey":c[2]||(c[2]=m=>f.isRef(r)?r.value=m:null)},{default:f.withCtx(()=>[f.createVNode(d,{key:"1",header:s.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(p,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(u,{label:s.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(l,{value:i.value.id,"onUpdate:value":c[0]||(c[0]=m=>i.value.id=m),placeholder:s.$t("common.plsEnter"),readonly:"",onClick:a},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(u,{label:s.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(l,{value:i.value.name,"onUpdate:value":c[1]||(c[1]=m=>i.value.name=m),placeholder:s.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),DD=f.defineComponent({__name:"Other",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const t=f.useModel(e,"formState"),n=f.ref(["1","2","3","4","5","6"]);return(i,r)=>{const o=U.Input,a=U.FormItem,s=U.Form,c=U.CollapsePanel,l=U.Collapse;return f.openBlock(),f.createBlock(l,{activeKey:f.unref(n),"onUpdate:activeKey":r[2]||(r[2]=u=>f.isRef(n)?n.value=u:null)},{default:f.withCtx(()=>[f.createVNode(c,{key:"1",header:i.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(s,{layout:"vertical",model:t.value},{default:f.withCtx(()=>[f.createVNode(a,{label:i.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.id,"onUpdate:value":r[0]||(r[0]=u=>t.value.id=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.name,"onUpdate:value":r[1]||(r[1]=u=>t.value.name=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),ND={class:"properties-panel"},OD=bn(f.defineComponent({__name:"BpmnPropertiesPanel",props:{modeler:{type:an},isEdit:{type:Boolean},isApproval:{type:Boolean}},setup(e){const t=e,n=f.ref(""),i=f.ref({});let r,o,a;f.watch(()=>t.modeler,()=>{t.modeler&&(r=t.modeler,s())}),f.watch(i,(u,p)=>{u===p&&l()},{deep:!0});function s(){o=r.get("modeling"),r.on("element.click",u=>{c(u.element)}),r.on("selection.changed",u=>{if(u.newSelection.length)c(u.newSelection[0]);else{const p=r.get("canvas").getRootElement();c(p)}})}function c(u){if(!(u!=null&&u.businessObject)||a===u)return;a=u;const p=u.businessObject,d=p.$type;n.value="",f.nextTick(()=>{n.value=d});const h={...p.$attrs};Object.keys(p).forEach(m=>{const y=p[m];typeof y=="string"&&(h[m]=y)}),d==="bpmn:UserTask"?(Object.assign(h,{rollback:h["camunda:rollback"]==="1"?"1":"0",approvalCheckbox:[]}),Object.assign(h,{approvalSign:h["camunda:countersign"]==="true"?"countersign":"orSign",approvalCheckbox:[]}),h["camunda:advice"]==="true"&&h.approvalCheckbox.push("advice"),h["camunda:attachment"]==="true"&&h.approvalCheckbox.push("attachment"),h["camunda:bindComponent"]&&(h.bindComponent=h["camunda:bindComponent"]),h.userArr=(h.candidateUsers||"").split(",").filter(m=>m),h.roleArr=(h.candidateGroups||"").split(",").filter(m=>m)):d==="bpmn:SequenceFlow"&&p.conditionExpression&&Object.assign(h,{condType:p.conditionExpression.$type,condBody:p.conditionExpression.body}),i.value=h}function l(){var m,y;const u=i.value;function p(g){return g?"true":"false"}const d={id:u.id,name:u.name},h=n.value;if(h==="bpmn:Process")u.jobPriority&&Object.assign(d,{"camunda:jobPriority":u.jobPriority});else if(h==="bpmn:UserTask")Object.assign(d,{"camunda:orSign":p(u.approvalSign==="orSign"),"camunda:rollback":u.rollback==="1"?"1":"0","camunda:countersign":p(u.approvalSign==="countersign"),"camunda:advice":p(u.approvalCheckbox.includes("advice")),"camunda:attachment":p(u.approvalCheckbox.includes("attachment")),"camunda:assignee":u.assignee||void 0,"camunda:assigneeName":u["camunda:assigneeName"]||void 0,"camunda:priority":u.priority||void 0,"camunda:candidateUsers":((m=u.userArr)==null?void 0:m.join())||void 0,"camunda:candidateGroups":((y=u.roleArr)==null?void 0:y.join())||void 0,"camunda:bindComponent":u.bindComponent});else if(h==="bpmn:SequenceFlow")if(u.condType){const g=r.get("moddle").create("bpmn:FormalExpression",{body:u.condBody});d.conditionExpression=g}else d.conditionExpression=null;o.updateProperties(a,d)}return(u,p)=>{const d=tf;return f.openBlock(),f.createElementBlock("div",ND,[f.createVNode(d,null,{default:f.withCtx(()=>[f.unref(n)==="bpmn:Process"?(f.openBlock(),f.createBlock(bD,{key:0,formState:f.unref(i),"onUpdate:formState":p[0]||(p[0]=h=>f.isRef(i)?i.value=h:null),isEdit:e.isEdit},null,8,["formState","isEdit"])):f.unref(n)==="bpmn:UserTask"?(f.openBlock(),f.createBlock(RD,{key:1,formState:f.unref(i),"onUpdate:formState":p[1]||(p[1]=h=>f.isRef(i)?i.value=h:null),isApproval:e.isApproval},null,8,["formState","isApproval"])):f.unref(n)==="bpmn:ExclusiveGateway"?(f.openBlock(),f.createBlock(TD,{key:2,formState:f.unref(i),"onUpdate:formState":p[2]||(p[2]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.unref(n)==="bpmn:SequenceFlow"?(f.openBlock(),f.createBlock(PD,{key:3,formState:f.unref(i),"onUpdate:formState":p[3]||(p[3]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.unref(n)==="bpmn:EndEvent"?(f.openBlock(),f.createBlock(MD,{key:4,formState:f.unref(i),"onUpdate:formState":p[4]||(p[4]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.unref(n)?(f.openBlock(),f.createBlock(DD,{key:5,formState:f.unref(i),"onUpdate:formState":p[5]||(p[5]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.createCommentVNode("",!0)]),_:1})])}}}),[["__scopeId","data-v-31b3ee78"]]),ID={class:"wrapper"},BD=bn(f.defineComponent({__name:"index",props:{data:{type:Object,required:!0}},setup(e,{expose:t}){const n=e,i=f.shallowRef();function r(){i.value=new an({container:"#canvas",moddleExtensions:{camunda:lD}})}function o(){ct.getBpmnXml({code:n.data.code}).then(s=>{var c;if(s.code===0){const l=s.result.text;(c=i.value)==null||c.importXML(l)}})}f.onMounted(()=>{var s;r(),n.data.code?o():(s=i.value)==null||s.createDiagram()});function a(){var s;return(s=i.value)==null?void 0:s.saveXML({format:!0})}return t({saveXML:a}),(s,c)=>(f.openBlock(),f.createElementBlock("div",ID,[c[0]||(c[0]=f.createElementVNode("div",{id:"canvas"},null,-1)),f.createVNode(OD,{modeler:f.unref(i),isEdit:e.data.opType==="2",isApproval:e.data.isApproval},null,8,["modeler","isEdit","isApproval"])]))}}),[["__scopeId","data-v-5f499ed0"]]),LD={class:"icon",viewBox:"0 0 1024 1024",width:"1.2em",height:"1.2em"};function $D(e,t){return f.openBlock(),f.createElementBlock("svg",LD,t[0]||(t[0]=[f.createElementVNode("path",{fill:"currentColor",d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 0 0 0 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281l360-281.1c3.8-3 6.1-7.7 6.1-12.6"},null,-1)]))}const jD=f.markRaw({name:"ant-design-left",render:$D}),FD={class:"container"},HD={class:"viewer-container"},VD=bn(f.defineComponent({__name:"BpmnEditPage",props:{data:{type:Object,required:!0}},setup(e){const{t}=Zt.useI18n(),n=e,i=f.computed(()=>{const c=n.data.opType||"1";if(c==="1")return t("bpmn.add_workflow");if(c==="2")return t("bpmn.edit_workflow");if(c==="3")return t("bpmn.clone_workflow")}),r=f.inject(Ko);function o(){r==null||r.emit("changeComp",{comp:"BusTypeList"})}const a=f.ref();function s(){var c;(c=a.value)==null||c.saveXML().then(({error:l,xml:u})=>{if(l){Qe.message.error(l);return}const p={type:n.data.type,text:u};((n.data.opType||"1")==="2"?ct.bpmnUpdate(p):ct.bpmnInsert(p)).then(m=>{m.code===0&&(r==null||r.emit("changeComp",{comp:"BusTypeList"}))})})}return(c,l)=>{const u=jD,p=U.Button,d=U.Space,h=U.PageHeader,m=BD;return f.openBlock(),f.createElementBlock("div",FD,[f.createVNode(h,{class:"page-header-sticky",title:f.unref(i),onBack:o},{backIcon:f.withCtx(()=>[f.createVNode(u)]),extra:f.withCtx(()=>[f.createVNode(d,null,{default:f.withCtx(()=>[f.createVNode(p,{type:"default",onClick:o},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(c.$t("common.btn_cancel")),1)]),_:1}),f.createVNode(p,{type:"primary",onClick:s},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(c.$t("common.btn_ok")),1)]),_:1})]),_:1})]),_:1},8,["title"]),f.createElementVNode("div",HD,[f.createVNode(m,{ref_key:"bpmnViewer",ref:a,data:e.data},null,8,["data"])])])}}}),[["__scopeId","data-v-e763e4dc"]]),zD={class:"wrapper"},WD=bn(f.defineComponent({components:{BusTypeList:EE,BpmnEditPage:VD},__name:"index",setup(e){const t=f.ref("BusTypeList"),n=f.ref(),i=M_(Ko);return f.provide(Ko,i),i.on((r,o)=>{r==="changeComp"&&(t.value=o.comp,n.value=o)}),(r,o)=>{const a=I_;return f.openBlock(),f.createBlock(a,null,{default:f.withCtx(()=>[f.createElementVNode("div",zD,[(f.openBlock(),f.createBlock(f.KeepAlive,{include:"BusTypeList"},[(f.openBlock(),f.createBlock(f.resolveDynamicComponent(f.unref(t)),{data:f.unref(n)},null,8,["data"]))],1024))])]),_:1})}}}),[["__scopeId","data-v-82fb5b00"]]);_p.createPinia();function UD(e){ic().setLang(e)}function GD(e,t){const{i18n:n,pinia:i,theme:r}=t;u_(n);const o=ic();o.setTheme(r),o.setupLangWatcher()}const KD={install:GD};bt.WfManagePage=WD,bt.default=KD,bt.setWorkflowLang=UD,Object.defineProperties(bt,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
240
+ </div>`,re.RESULT_HTML='<div class="djs-search-result"></div>',re.RESULT_PRIMARY_HTML='<div class="djs-search-result-primary"></div>',re.RESULT_SECONDARY_HTML='<p class="djs-search-result-secondary"></p>';const eD={__depends__:[wa,Ra,tn],searchPad:["type",re]};function vp(e,t,n,i){this._elementRegistry=e,this._canvas=n,this._search=i,t.registerProvider(this)}vp.$inject=["elementRegistry","searchPad","canvas","search"],vp.prototype.find=function(e){var t=this._canvas.getRootElements(),n=this._elementRegistry.filter(function(i){return!ge(i)&&!t.includes(i)});return this._search(n.map(i=>({element:i,label:en(i),id:i.id})),e,{keys:["label","id"]}).map(tD)};function tD(e){const{item:{element:t},tokens:n}=e;return{element:t,primaryTokens:n.label,secondaryTokens:n.id}}const nD={__depends__:[eD,Gh],__init__:["bpmnSearch"],bpmnSearch:["type",vp]},iD="M44.7648 11.3263L36.9892 2.64074C36.0451 1.58628 34.5651 0.988708 33.1904 0.988708H5.98667C3.22688 0.988708 0.989624 3.34892 0.989624 6.26039V55.0235C0.989624 57.9349 3.22688 60.2952 5.98667 60.2952H40.966C43.7257 60.2952 45.963 57.9349 45.963 55.0235V14.9459C45.963 13.5998 45.6407 12.3048 44.7648 11.3263Z",rD="M1.03845 48.1347C1.03845 49.3511 1.07295 50.758 1.38342 52.064C1.69949 53.3938 2.32428 54.7154 3.56383 55.6428C6.02533 57.4841 10.1161 58.7685 14.8212 59.6067C19.5772 60.4538 25.1388 60.8738 30.6831 60.8738C36.2276 60.8738 41.7891 60.4538 46.545 59.6067C51.2504 58.7687 55.3412 57.4842 57.8028 55.6429C59.0424 54.7156 59.6673 53.3938 59.9834 52.064C60.2938 50.7579 60.3285 49.351 60.3285 48.1344V13.8415C60.3285 12.6249 60.2938 11.218 59.9834 9.91171C59.6673 8.58194 59.0423 7.2602 57.8027 6.33294C55.341 4.49168 51.2503 3.20723 46.545 2.36914C41.7891 1.522 36.2276 1.10204 30.6831 1.10205C25.1388 1.10206 19.5772 1.52206 14.8213 2.36923C10.1162 3.20734 6.02543 4.49183 3.5639 6.33314C2.32433 7.26038 1.69951 8.58206 1.38343 9.91181C1.07295 11.2179 1.03845 12.6247 1.03845 13.8411V48.1347Z",oD={width:36,height:50},aD={width:50,height:50};function s_(e,t,n){return X("path",{d:e,strokeWidth:2,transform:`translate(${t.x}, ${t.y})`,...n})}const Cr=5;function Js(e,t){this._styles=t,e.registerProvider(this)}Js.$inject=["outline","styles"],Js.prototype.getOutline=function(e){const t=this._styles.cls("djs-outline",["no-fill"]);var n;if(!ge(e))return E(e,"bpmn:Gateway")?(n=X("rect"),D(n.style,{"transform-box":"fill-box",transform:"rotate(45deg)","transform-origin":"center"}),q(n,D({x:2,y:2,rx:4,width:e.width-4,height:e.height-4},t))):ue(e,["bpmn:Task","bpmn:SubProcess","bpmn:Group","bpmn:CallActivity"])?(n=X("rect"),q(n,D({x:-5,y:-5,rx:14,width:e.width+Cr*2,height:e.height+Cr*2},t))):E(e,"bpmn:EndEvent")?(n=X("circle"),q(n,D({cx:e.width/2,cy:e.height/2,r:e.width/2+Cr+1},t))):E(e,"bpmn:Event")?(n=X("circle"),q(n,D({cx:e.width/2,cy:e.height/2,r:e.width/2+Cr},t))):E(e,"bpmn:DataObjectReference")&&c_(e,"bpmn:DataObjectReference")?n=s_(iD,{x:-6,y:-6},t):E(e,"bpmn:DataStoreReference")&&c_(e,"bpmn:DataStoreReference")&&(n=s_(rD,{x:-6,y:-6},t)),n},Js.prototype.updateOutline=function(e,t){if(!ge(e))return ue(e,["bpmn:SubProcess","bpmn:Group"])?(q(t,{width:e.width+Cr*2,height:e.height+Cr*2}),!0):!!ue(e,["bpmn:Event","bpmn:Gateway","bpmn:DataStoreReference","bpmn:DataObjectReference"])};function c_(e,t){var n;return t==="bpmn:DataObjectReference"?n=oD:t==="bpmn:DataStoreReference"&&(n=aD),e.width===n.width&&e.height===n.height}const sD={__depends__:[Nv],__init__:["outlineProvider"],outlineProvider:["type",Js]};var cD='<?xml version="1.0" encoding="UTF-8"?><bpmn:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 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" targetNamespace="http://bpmn.io/schema/bpmn" id="Definitions_1"><bpmn:process id="Process_1" isExecutable="false"><bpmn:startEvent id="StartEvent_1"/></bpmn:process><bpmndi:BPMNDiagram id="BPMNDiagram_1"><bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Process_1"><bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="StartEvent_1"><dc:Bounds height="36.0" width="36.0" x="173.0" y="102.0"/></bpmndi:BPMNShape></bpmndi:BPMNPlane></bpmndi:BPMNDiagram></bpmn:definitions>';function an(e){zr.call(this,e)}Y(an,zr),an.Viewer=Zn,an.NavigatedViewer=Zr,an.prototype.createDiagram=function(){return this.importXML(cD)},an.prototype._interactionModules=[eh,rh,sh],an.prototype._modelingModules=[sR,Rl,kR,SR,XR,Ll,nT,l2,ny,Es,d2,g2,M2,N2,O2,j2,Z2,Yy,rM,mM,CM,TM,Tv,JM,nD,sD],an.prototype._modules=[].concat(Zn.prototype._modules,an.prototype._interactionModules,an.prototype._modelingModules);const lD={name:"Camunda",uri:"http://camunda.org/schema/1.0/bpmn",prefix:"camunda",xml:{tagAlias:"lowerCase"},associations:[],types:JSON.parse('[{"name":"Definitions","isAbstract":true,"extends":["bpmn:Definitions"],"properties":[{"name":"diagramRelationId","isAttr":true,"type":"String"}]},{"name":"InOutBinding","superClass":["Element"],"isAbstract":true,"properties":[{"name":"source","isAttr":true,"type":"String"},{"name":"sourceExpression","isAttr":true,"type":"String"},{"name":"target","isAttr":true,"type":"String"},{"name":"businessKey","isAttr":true,"type":"String"},{"name":"local","isAttr":true,"type":"Boolean","default":false},{"name":"variables","isAttr":true,"type":"String"}]},{"name":"In","superClass":["InOutBinding"],"meta":{"allowedIn":["bpmn:CallActivity","bpmn:SignalEventDefinition"]}},{"name":"Out","superClass":["InOutBinding"],"meta":{"allowedIn":["bpmn:CallActivity"]}},{"name":"AsyncCapable","isAbstract":true,"extends":["bpmn:Activity","bpmn:Gateway","bpmn:Event"],"properties":[{"name":"async","isAttr":true,"type":"Boolean","default":false},{"name":"asyncBefore","isAttr":true,"type":"Boolean","default":false},{"name":"asyncAfter","isAttr":true,"type":"Boolean","default":false},{"name":"exclusive","isAttr":true,"type":"Boolean","default":true}]},{"name":"JobPriorized","isAbstract":true,"extends":["bpmn:Process","camunda:AsyncCapable"],"properties":[{"name":"jobPriority","isAttr":true,"type":"String"}]},{"name":"SignalEventDefinitionExtension","isAbstract":true,"extends":["bpmn:SignalEventDefinition"],"properties":[{"name":"async","isAttr":true,"type":"Boolean","default":false}]},{"name":"ErrorEventDefinitionExtension","isAbstract":true,"extends":["bpmn:ErrorEventDefinition"],"properties":[{"name":"errorCodeVariable","isAttr":true,"type":"String"},{"name":"errorMessageVariable","isAttr":true,"type":"String"}]},{"name":"ErrorEventDefinition","superClass":["bpmn:ErrorEventDefinition","Element"],"properties":[{"name":"expression","isAttr":true,"type":"String"}],"meta":{"allowedIn":["bpmn:ServiceTask"]}},{"name":"Error","isAbstract":true,"extends":["bpmn:Error"],"properties":[{"name":"camunda:errorMessage","isAttr":true,"type":"String"}]},{"name":"PotentialStarter","superClass":["Element"],"properties":[{"name":"resourceAssignmentExpression","type":"bpmn:ResourceAssignmentExpression"}]},{"name":"FormSupported","isAbstract":true,"extends":["bpmn:StartEvent","bpmn:UserTask"],"properties":[{"name":"formHandlerClass","isAttr":true,"type":"String"},{"name":"formKey","isAttr":true,"type":"String"},{"name":"formRef","isAttr":true,"type":"String"},{"name":"formRefBinding","isAttr":true,"type":"String"},{"name":"formRefVersion","isAttr":true,"type":"String"}]},{"name":"TemplateSupported","isAbstract":true,"extends":["bpmn:Collaboration","bpmn:Process","bpmn:FlowElement"],"properties":[{"name":"modelerTemplate","isAttr":true,"type":"String"},{"name":"modelerTemplateVersion","isAttr":true,"type":"Integer"}]},{"name":"Initiator","isAbstract":true,"extends":["bpmn:StartEvent"],"properties":[{"name":"initiator","isAttr":true,"type":"String"}]},{"name":"ScriptTask","isAbstract":true,"extends":["bpmn:ScriptTask"],"properties":[{"name":"resultVariable","isAttr":true,"type":"String"},{"name":"resource","isAttr":true,"type":"String"}]},{"name":"Process","isAbstract":true,"extends":["bpmn:Process"],"properties":[{"name":"candidateStarterGroups","isAttr":true,"type":"String"},{"name":"candidateStarterUsers","isAttr":true,"type":"String"},{"name":"versionTag","isAttr":true,"type":"String"},{"name":"historyTimeToLive","isAttr":true,"type":"String"},{"name":"isStartableInTasklist","isAttr":true,"type":"Boolean","default":true}]},{"name":"EscalationEventDefinitionExtension","isAbstract":true,"extends":["bpmn:EscalationEventDefinition"],"properties":[{"name":"escalationCodeVariable","isAttr":true,"type":"String"}]},{"name":"FormalExpression","isAbstract":true,"extends":["bpmn:FormalExpression"],"properties":[{"name":"resource","isAttr":true,"type":"String"}]},{"name":"Assignable","extends":["bpmn:UserTask"],"properties":[{"name":"assignee","isAttr":true,"type":"String"},{"name":"candidateUsers","isAttr":true,"type":"String"},{"name":"candidateGroups","isAttr":true,"type":"String"},{"name":"dueDate","isAttr":true,"type":"String"},{"name":"followUpDate","isAttr":true,"type":"String"},{"name":"priority","isAttr":true,"type":"String"}]},{"name":"CallActivity","extends":["bpmn:CallActivity"],"properties":[{"name":"calledElementBinding","isAttr":true,"type":"String","default":"latest"},{"name":"calledElementVersion","isAttr":true,"type":"String"},{"name":"calledElementVersionTag","isAttr":true,"type":"String"},{"name":"calledElementTenantId","isAttr":true,"type":"String"},{"name":"caseRef","isAttr":true,"type":"String"},{"name":"caseBinding","isAttr":true,"type":"String","default":"latest"},{"name":"caseVersion","isAttr":true,"type":"String"},{"name":"caseTenantId","isAttr":true,"type":"String"},{"name":"variableMappingClass","isAttr":true,"type":"String"},{"name":"variableMappingDelegateExpression","isAttr":true,"type":"String"}]},{"name":"ServiceTaskLike","extends":["bpmn:ServiceTask","bpmn:BusinessRuleTask","bpmn:SendTask","bpmn:MessageEventDefinition"],"properties":[{"name":"expression","isAttr":true,"type":"String"},{"name":"class","isAttr":true,"type":"String"},{"name":"delegateExpression","isAttr":true,"type":"String"},{"name":"resultVariable","isAttr":true,"type":"String"}]},{"name":"DmnCapable","extends":["bpmn:BusinessRuleTask"],"properties":[{"name":"decisionRef","isAttr":true,"type":"String"},{"name":"decisionRefBinding","isAttr":true,"type":"String","default":"latest"},{"name":"decisionRefVersion","isAttr":true,"type":"String"},{"name":"mapDecisionResult","isAttr":true,"type":"String","default":"resultList"},{"name":"decisionRefTenantId","isAttr":true,"type":"String"}]},{"name":"ExternalCapable","extends":["camunda:ServiceTaskLike"],"properties":[{"name":"type","isAttr":true,"type":"String"},{"name":"topic","isAttr":true,"type":"String"}]},{"name":"TaskPriorized","extends":["bpmn:Process","camunda:ExternalCapable"],"properties":[{"name":"taskPriority","isAttr":true,"type":"String"}]},{"name":"Properties","superClass":["Element"],"meta":{"allowedIn":["*"]},"properties":[{"name":"values","type":"Property","isMany":true}]},{"name":"Property","superClass":["Element"],"properties":[{"name":"id","type":"String","isAttr":true},{"name":"name","type":"String","isAttr":true},{"name":"value","type":"String","isAttr":true}]},{"name":"Connector","superClass":["Element"],"meta":{"allowedIn":["camunda:ServiceTaskLike"]},"properties":[{"name":"inputOutput","type":"InputOutput"},{"name":"connectorId","type":"String"}]},{"name":"InputOutput","superClass":["Element"],"meta":{"allowedIn":["bpmn:FlowNode","camunda:Connector"]},"properties":[{"name":"inputOutput","type":"InputOutput"},{"name":"connectorId","type":"String"},{"name":"inputParameters","isMany":true,"type":"InputParameter"},{"name":"outputParameters","isMany":true,"type":"OutputParameter"}]},{"name":"InputOutputParameter","properties":[{"name":"name","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"},{"name":"definition","type":"InputOutputParameterDefinition"}]},{"name":"InputOutputParameterDefinition","isAbstract":true},{"name":"List","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"items","isMany":true,"type":"InputOutputParameterDefinition"}]},{"name":"Map","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"entries","isMany":true,"type":"Entry"}]},{"name":"Entry","properties":[{"name":"key","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"},{"name":"definition","type":"InputOutputParameterDefinition"}]},{"name":"Value","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"id","isAttr":true,"type":"String"},{"name":"name","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"}]},{"name":"Script","superClass":["InputOutputParameterDefinition"],"properties":[{"name":"scriptFormat","isAttr":true,"type":"String"},{"name":"resource","isAttr":true,"type":"String"},{"name":"value","isBody":true,"type":"String"}]},{"name":"Field","superClass":["Element"],"meta":{"allowedIn":["camunda:ServiceTaskLike","camunda:ExecutionListener","camunda:TaskListener"]},"properties":[{"name":"name","isAttr":true,"type":"String"},{"name":"expression","type":"String"},{"name":"stringValue","isAttr":true,"type":"String"},{"name":"string","type":"String"}]},{"name":"InputParameter","superClass":["InputOutputParameter"]},{"name":"OutputParameter","superClass":["InputOutputParameter"]},{"name":"Collectable","isAbstract":true,"extends":["bpmn:MultiInstanceLoopCharacteristics"],"superClass":["camunda:AsyncCapable"],"properties":[{"name":"collection","isAttr":true,"type":"String"},{"name":"elementVariable","isAttr":true,"type":"String"}]},{"name":"FailedJobRetryTimeCycle","superClass":["Element"],"meta":{"allowedIn":["camunda:AsyncCapable","bpmn:MultiInstanceLoopCharacteristics"]},"properties":[{"name":"body","isBody":true,"type":"String"}]},{"name":"ExecutionListener","superClass":["Element"],"meta":{"allowedIn":["bpmn:Task","bpmn:ServiceTask","bpmn:UserTask","bpmn:BusinessRuleTask","bpmn:ScriptTask","bpmn:ReceiveTask","bpmn:ManualTask","bpmn:ExclusiveGateway","bpmn:SequenceFlow","bpmn:ParallelGateway","bpmn:InclusiveGateway","bpmn:EventBasedGateway","bpmn:StartEvent","bpmn:IntermediateCatchEvent","bpmn:IntermediateThrowEvent","bpmn:EndEvent","bpmn:BoundaryEvent","bpmn:CallActivity","bpmn:SubProcess","bpmn:Process"]},"properties":[{"name":"expression","isAttr":true,"type":"String"},{"name":"class","isAttr":true,"type":"String"},{"name":"delegateExpression","isAttr":true,"type":"String"},{"name":"event","isAttr":true,"type":"String"},{"name":"script","type":"Script"},{"name":"fields","type":"Field","isMany":true}]},{"name":"TaskListener","superClass":["Element"],"meta":{"allowedIn":["bpmn:UserTask"]},"properties":[{"name":"expression","isAttr":true,"type":"String"},{"name":"class","isAttr":true,"type":"String"},{"name":"delegateExpression","isAttr":true,"type":"String"},{"name":"event","isAttr":true,"type":"String"},{"name":"script","type":"Script"},{"name":"fields","type":"Field","isMany":true},{"name":"id","type":"String","isAttr":true},{"name":"eventDefinitions","type":"bpmn:TimerEventDefinition","isMany":true}]},{"name":"FormProperty","superClass":["Element"],"meta":{"allowedIn":["bpmn:StartEvent","bpmn:UserTask"]},"properties":[{"name":"id","type":"String","isAttr":true},{"name":"name","type":"String","isAttr":true},{"name":"type","type":"String","isAttr":true},{"name":"required","type":"String","isAttr":true},{"name":"readable","type":"String","isAttr":true},{"name":"writable","type":"String","isAttr":true},{"name":"variable","type":"String","isAttr":true},{"name":"expression","type":"String","isAttr":true},{"name":"datePattern","type":"String","isAttr":true},{"name":"default","type":"String","isAttr":true},{"name":"values","type":"Value","isMany":true}]},{"name":"FormData","superClass":["Element"],"meta":{"allowedIn":["bpmn:StartEvent","bpmn:UserTask"]},"properties":[{"name":"fields","type":"FormField","isMany":true},{"name":"businessKey","type":"String","isAttr":true}]},{"name":"FormField","superClass":["Element"],"properties":[{"name":"id","type":"String","isAttr":true},{"name":"label","type":"String","isAttr":true},{"name":"type","type":"String","isAttr":true},{"name":"datePattern","type":"String","isAttr":true},{"name":"defaultValue","type":"String","isAttr":true},{"name":"properties","type":"Properties"},{"name":"validation","type":"Validation"},{"name":"values","type":"Value","isMany":true}]},{"name":"Validation","superClass":["Element"],"properties":[{"name":"constraints","type":"Constraint","isMany":true}]},{"name":"Constraint","superClass":["Element"],"properties":[{"name":"name","type":"String","isAttr":true},{"name":"config","type":"String","isAttr":true}]},{"name":"ConditionalEventDefinitionExtension","isAbstract":true,"extends":["bpmn:ConditionalEventDefinition"],"properties":[{"name":"variableName","isAttr":true,"type":"String"},{"name":"variableEvents","isAttr":true,"type":"String"}]}]'),emumerations:[]},uD=bn(f.defineComponent({inheritAttrs:!1,__name:"index",props:f.mergeModels({dictType:{type:String,default:""},include:{type:[Array,String]},exclude:{type:Array},sort:{type:Boolean}},{dictMap:{type:Object},dictMapModifiers:{}}),emits:["update:dictMap"],setup(e){const t=e,n=f.useModel(e,"dictMap"),[i,{fetchDict:r,toList:o}]=Sp(t.dictType,{immediate:!1}),a=f.computed(()=>{var c;const s=o(t.dictType);if(t.sort&&s.sort((l,u)=>parseFloat(l.value)-parseFloat(u.value)),t.include){const l=typeof t.include=="string"?t.include.split(","):t.include;return s.filter(u=>l.includes(u.value))}return(c=t.exclude)!=null&&c.length?s.filter(l=>{var u;return!((u=t.exclude)!=null&&u.includes(l.value))}):s});return t.dictType&&r(),f.watch(()=>i.value,()=>{if(n.value&&typeof n.value=="object")for(const s in i.value)n.value[s]=i.value}),(s,c)=>{const l=U.Select;return f.openBlock(),f.createBlock(l,f.mergeProps({class:"dict-select",placeholder:s.$t("common.plsSelect"),showSearch:!1,options:f.unref(a),dropdownMatchSelectWidth:!1},s.$attrs),null,16,["placeholder","options"])}}}),[["__scopeId","data-v-02a7899b"]]),pD={class:"icon",viewBox:"0 0 1024 1024",width:"1.2em",height:"1.2em"};function fD(e,t){return f.openBlock(),f.createElementBlock("svg",pD,t[0]||(t[0]=[f.createElementVNode("path",{fill:"currentColor",d:"M512 64C264.6 64 64 264.6 64 512s200.6 448 448 448s448-200.6 448-448S759.4 64 512 64m0 820c-205.4 0-372-166.6-372-372s166.6-372 372-372s372 166.6 372 372s-166.6 372-372 372"},null,-1),f.createElementVNode("path",{fill:"currentColor",d:"M623.6 316.7C593.6 290.4 554 276 512 276s-81.6 14.5-111.6 40.7C369.2 344 352 380.7 352 420v7.6c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8V420c0-44.1 43.1-80 96-80s96 35.9 96 80c0 31.1-22 59.6-56.1 72.7c-21.2 8.1-39.2 22.3-52.1 40.9c-13.1 19-19.9 41.8-19.9 64.9V620c0 4.4 3.6 8 8 8h48c4.4 0 8-3.6 8-8v-22.7a48.3 48.3 0 0 1 30.9-44.8c59-22.7 97.1-74.7 97.1-132.5c.1-39.3-17.1-76-48.3-103.3M472 732a40 40 0 1 0 80 0a40 40 0 1 0-80 0"},null,-1)]))}const dD=f.markRaw({name:"ant-design-question-circle",render:fD}),hD={class:"wrapper"},mD={class:"mt-xs"},gD={class:"flex-sc"},yD={class:"mt-xs"},vD={style:{maxWidth:"281px",overflow:"hidden",whiteSpace:"break-spaces"}},_D=bn(f.defineComponent({__name:"RuleConfig",props:{jsonStr:{type:String,required:!0}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({});function a(p){const d=p.replace(/(false|true|\d+)(?=")/g,"$1,");return JSON.parse(`{${d}}`)}function s(p){if(typeof p=="string"&&(p.trim().startsWith("{")||p.trim().startsWith("[")))try{return JSON.parse(p),!0}catch{return!1}return!1}function c(){i.jsonStr?(s(i.jsonStr)?o.value=JSON.parse(i.jsonStr):o.value=a(i.jsonStr),o.value.fallbackFirstLinkStatus!==null&&o.value.fallbackFirstLinkStatus!==void 0&&(o.value.fallbackFirstLinkStatus=String(o.value.fallbackFirstLinkStatus))):o.value={revokeRule:!1,fallbackRule:!1,approverRemoveDuplicates:2,timeoutConfigSwitch:!1,timeoutPeriod:1,timeoutHandler:1,fallbackFirstLinkStatus:null}}function l(){Qe.Modal.destroyAll()}function u(){const p=o.value;if(p.timeoutConfigSwitch&&!p.timeoutPeriod){Qe.message.warning(n("bpmn.timeoutPeriodEmptyTip"));return}p.fallbackFirstLinkStatus&&(p.fallbackFirstLinkStatus=Number(p.fallbackFirstLinkStatus)),r("submit",o.value),Qe.Modal.destroyAll()}return f.onMounted(()=>{c()}),(p,d)=>{const h=U.Checkbox,m=U.FormItem,y=U.Radio,g=U.RadioGroup,w=U.InputNumber,C=dD,x=U.Tooltip,b=uD,S=U.Form,P=U.Button,M=U.Space;return f.openBlock(),f.createElementBlock("div",hD,[f.createVNode(S,{class:"my-nm","label-col":{span:9},"wrapper-col":{span:15},colon:!1,model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(m,{label:p.$t("bpmn.revertRule")},{default:f.withCtx(()=>[f.createVNode(h,{checked:f.unref(o).revokeRule,"onUpdate:checked":d[0]||(d[0]=R=>f.unref(o).revokeRule=R)},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.revertRuleTxt")),1)]),_:1},8,["checked"])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.rollbackRule")},{default:f.withCtx(()=>[f.createVNode(h,{checked:f.unref(o).fallbackRule,"onUpdate:checked":d[1]||(d[1]=R=>f.unref(o).fallbackRule=R)},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.rollbackRuleTxt")),1)]),_:1},8,["checked"])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.deduplicationApprovers")},{default:f.withCtx(()=>[f.createElementVNode("div",mD,f.toDisplayString(p.$t("bpmn.deduplicationApproversTxt")),1),f.createVNode(g,{value:f.unref(o).approverRemoveDuplicates,"onUpdate:value":d[2]||(d[2]=R=>f.unref(o).approverRemoveDuplicates=R)},{default:f.withCtx(()=>[f.createVNode(y,{value:0},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.deduplicationRadio0")),1)]),_:1}),f.createVNode(y,{value:1},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.deduplicationRadio1")),1)]),_:1}),f.createVNode(y,{value:2},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.deduplicationRadio2")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.timeoutRule")},{default:f.withCtx(()=>[f.createVNode(h,{checked:f.unref(o).timeoutConfigSwitch,"onUpdate:checked":d[3]||(d[3]=R=>f.unref(o).timeoutConfigSwitch=R)},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.timeoutRuleTxt")),1)]),_:1},8,["checked"])]),_:1},8,["label"]),f.unref(o).timeoutConfigSwitch?(f.openBlock(),f.createElementBlock(f.Fragment,{key:0},[f.createVNode(m,{label:p.$t("wo_my.timeout")},{default:f.withCtx(()=>[f.createElementVNode("div",gD,[f.createTextVNode(f.toDisplayString(p.$t("bpmn.linkTimeoutTxt1"))+" ",1),f.createVNode(w,{class:"mx-xs",value:f.unref(o).timeoutPeriod,"onUpdate:value":d[4]||(d[4]=R=>f.unref(o).timeoutPeriod=R),min:1,max:1e4,precision:0},null,8,["value"]),f.createTextVNode(" "+f.toDisplayString(p.$t("bpmn.linkTimeoutTxt2")),1)])]),_:1},8,["label"]),f.createVNode(m,{label:p.$t("bpmn.timeoutHandle")},{default:f.withCtx(()=>[f.createElementVNode("div",yD,f.toDisplayString(p.$t("bpmn.timeoutHandleTxt")),1),f.createVNode(g,{value:f.unref(o).timeoutHandler,"onUpdate:value":d[5]||(d[5]=R=>f.unref(o).timeoutHandler=R)},{default:f.withCtx(()=>[f.createVNode(y,{value:0},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.timeoutHandleRadio0")),1)]),_:1}),f.createVNode(y,{value:1},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("bpmn.timeoutHandleRadio1")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["label"])],64)):f.createCommentVNode("",!0),f.createVNode(m,null,{label:f.withCtx(()=>[f.createElementVNode("span",vD,f.toDisplayString(p.$t("bpmn.fallbackFirstLinkStatus")),1),f.createVNode(x,{overlayInnerStyle:{width:"600px"}},{title:f.withCtx(()=>[f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip1")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip2")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip3")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip4")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip5")),1),f.createElementVNode("div",null,f.toDisplayString(p.$t("bpmn.rollbackTooltip6")),1)]),default:f.withCtx(()=>[f.createVNode(C)]),_:1})]),default:f.withCtx(()=>[f.createVNode(b,{"dict-type":"fallback_first_link_status",value:f.unref(o).fallbackFirstLinkStatus,"onUpdate:value":d[6]||(d[6]=R=>f.unref(o).fallbackFirstLinkStatus=R),placeholder:p.$t("common.plsSelect"),style:{width:"80%"}},null,8,["value","placeholder"])]),_:1})]),_:1},8,["model"]),f.createVNode(M,{class:"modal-btns"},{default:f.withCtx(()=>[f.createVNode(P,{onClick:l},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(P,{type:"primary",onClick:u},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(p.$t("common.btn_sure")),1)]),_:1})]),_:1})])}}}),[["__scopeId","data-v-e5654449"]]),bD=f.defineComponent({__name:"Process",props:f.mergeModels({isEdit:{type:Boolean}},{formState:{},formStateModifiers:{}}),emits:["update:formState"],setup(e){const{modal:t}=Qe.App.useApp(),{t:n}=Zt.useI18n(),i=f.useModel(e,"formState"),r=f.ref(["1","2","3","4","5","6"]);function o(){t.info({title:n("ruleModel.title"),content:f.h(_D,{jsonStr:i.value.jobPriority,onSubmit:a=>{i.value.jobPriority=JSON.stringify(a)}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:850,class:"modal-comp"})}return(a,s)=>{const c=U.Input,l=U.FormItem,u=U.Form,p=U.CollapsePanel,d=U.Collapse;return f.openBlock(),f.createBlock(d,{activeKey:f.unref(r),"onUpdate:activeKey":s[4]||(s[4]=h=>f.isRef(r)?r.value=h:null)},{default:f.withCtx(()=>[f.createVNode(p,{key:"1",header:a.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(u,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(l,{label:a.$t("FLOW_CHART.Id"),extra:a.$t("FLOW_CHART.idTip")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.id,"onUpdate:value":s[0]||(s[0]=h=>i.value.id=h),placeholder:a.$t("common.plsEnter"),readonly:e.isEdit},null,8,["value","placeholder","readonly"])]),_:1},8,["label","extra"]),f.createVNode(l,{label:a.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.name,"onUpdate:value":s[1]||(s[1]=h=>i.value.name=h),placeholder:a.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(l,{label:a.$t("FLOW_CHART.Version Tag")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.versionTag,"onUpdate:value":s[2]||(s[2]=h=>i.value.versionTag=h),disabled:""},null,8,["value"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"]),f.createVNode(p,{key:"4",header:a.$t("FLOW_CHART.Job Configuration")},{default:f.withCtx(()=>[f.createVNode(u,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(l,{label:a.$t("FLOW_CHART.Job Priority")},{default:f.withCtx(()=>[f.createVNode(c,{value:i.value.jobPriority,"onUpdate:value":s[3]||(s[3]=h=>i.value.jobPriority=h),placeholder:a.$t("common.plsSelect"),readonly:"",onClick:o},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),ED=bn(f.defineComponent({__name:"TemplateConfig",props:{data:{type:Object,default:()=>{}},templateList:{type:Array,default:()=>[]}},emits:["update:data"],setup(e,{emit:t}){const n=t,i=e,r=f.computed({get:()=>i.data,set:l=>{n("update:data",l)}}),o=f.computed(()=>i.templateList.filter(l=>{var u;return(u=l==null?void 0:l.type)==null?void 0:u.split(",").includes("1")}).map(l=>({label:l.name,value:l.id}))),a=f.computed(()=>i.templateList.filter(l=>{var u;return(u=l==null?void 0:l.type)==null?void 0:u.split(",").includes("2")}).map(l=>({label:l.name,value:l.id}))),s=f.computed(()=>i.templateList.filter(l=>{var u;return(u=l==null?void 0:l.type)==null?void 0:u.split(",").includes("3")}).map(l=>({label:l.name,value:l.id}))),c=(l,u)=>u.label.toLowerCase().indexOf(l.toLowerCase())>=0;return(l,u)=>{const p=U.Select,d=U.FormItem,h=U.Form;return f.openBlock(),f.createElementBlock("div",null,[f.createVNode(h,{class:"form-query-select mx-nm mt-nm",layout:"vertical",model:r.value},{default:f.withCtx(()=>[f.createVNode(d,{label:l.$t("待办工单处理")},{default:f.withCtx(()=>[f.createVNode(p,{value:r.value[1],"onUpdate:value":u[0]||(u[0]=m=>r.value[1]=m),options:o.value,allowClear:"",placeholder:l.$t("common.plsSelect"),"show-search":"","filter-option":c},null,8,["value","options","placeholder"])]),_:1},8,["label"]),f.createVNode(d,{label:l.$t("待办工单详情")},{default:f.withCtx(()=>[f.createVNode(p,{value:r.value[2],"onUpdate:value":u[1]||(u[1]=m=>r.value[2]=m),options:a.value,allowClear:"",placeholder:l.$t("common.plsSelect"),"show-search":"","filter-option":c},null,8,["value","options","placeholder"])]),_:1},8,["label"]),f.createVNode(d,{label:l.$t("全部工单详情")},{default:f.withCtx(()=>[f.createVNode(p,{value:r.value[3],"onUpdate:value":u[2]||(u[2]=m=>r.value[3]=m),options:s.value,allowClear:"",placeholder:l.$t("common.plsSelect"),"show-search":"","filter-option":c},null,8,["value","options","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])])}}}),[["__scopeId","data-v-5c46da3d"]]),xD={class:"modal-container"},wD=f.defineComponent({__name:"SelectLinkTask",props:{id:{type:String},componentInfo:{type:String,default:""},variable:{type:String,default:""},description:{type:String,default:""}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({}),a=f.ref([{title:n("link.id"),dataIndex:"id"},{title:n("link.description"),dataIndex:"description"},{title:n("link.due"),dataIndex:"due"},{title:n("link.variable"),dataIndex:"variable"},{title:n("bpmn.action"),dataIndex:"action"}]),s=f.ref([]),c=f.ref();function l(O,F){s.value=O,c.value=F}const u=f.ref({1:void 0,2:void 0,3:void 0}),p=f.ref({}),d=f.ref(!1),h=f.ref(""),m=f.ref("");function y(){d.value=!1,h.value=JSON.stringify(u.value)}function g(){d.value=!1}function w(O){p.value=O,d.value=!0}const C=f.ref([]);async function x(){const{result:O}=await ct.getTemplateList({pageNo:1,pageSize:1e3});C.value=(O==null?void 0:O.data)||[]}const b=f.ref([]);async function S(){const{result:O}=await ct.getLinkList({pageNo:1,pageSize:1e3});b.value=(O==null?void 0:O.data)||[]}f.watchEffect(()=>{i.id&&(i.id.startsWith("common-approve-")||i.id.startsWith("common-handle-")?(m.value=i.id.slice(-4),s.value=[i.id.slice(0,-4)+"*"]):s.value=[i.id]),i.componentInfo&&(u.value=JSON.parse(i.componentInfo)||{})});function P(O){c.value=null;const F={...o.value};return Object.assign(F,O),ct.getLinkList(F)}const M=f.ref(),R=()=>{M.value.refresh()},I=()=>{o.value={},R()};f.onMounted(()=>{I(),x(),S()});function B(){Qe.Modal.destroyAll()}function L(){var O,F;if((O=c.value)!=null&&O.length)r("submit",{...c.value[0],bindComponent:h.value,hasSuffix:""});else if((F=s.value)!=null&&F.length){const G=b.value.find(ke=>ke.id===s.value[0]);r("submit",{...G,id:i.id,bindComponent:h.value,hasSuffix:m.value})}Qe.Modal.destroyAll()}return(O,F)=>{const G=U.Input,ke=U.FormItem,be=U.Button,ce=U.Space,st=U.Form,We=U.Tooltip,Ee=f.resolveComponent("a-table-ex"),Te=U.Modal;return f.openBlock(),f.createElementBlock(f.Fragment,null,[f.createElementVNode("div",xD,[f.createVNode(st,{class:"form-query mx-nm mt-nm",layout:"vertical",model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(ke,{label:O.$t("link.id")},{default:f.withCtx(()=>[f.createVNode(G,{value:f.unref(o).id,"onUpdate:value":F[0]||(F[0]=$=>f.unref(o).id=$),placeholder:O.$t("common.plsEnter"),onKeydown:f.withKeys(R,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(ke,{label:O.$t("link.description")},{default:f.withCtx(()=>[f.createVNode(G,{value:f.unref(o).description,"onUpdate:value":F[1]||(F[1]=$=>f.unref(o).description=$),placeholder:O.$t("common.plsEnter"),onKeydown:f.withKeys(R,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(ke,{class:"form-btns"},{default:f.withCtx(()=>[f.createVNode(ce,null,{default:f.withCtx(()=>[f.createVNode(be,{type:"primary",onClick:R},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_search")),1)]),_:1}),f.createVNode(be,{onClick:I},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_reset")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),f.createVNode(Ee,{ref_key:"tableEx",ref:M,class:"table-query bordered mx-nm",columns:f.unref(a),rowKey:"id","row-selection":{type:"radio",selectedRowKeys:f.unref(s),onChange:l},loadData:P},{bodyCell:f.withCtx(({record:$,column:H})=>[H.dataIndex==="action"?(f.openBlock(),f.createBlock(We,{key:0,placement:"top"},{title:f.withCtx(()=>[f.createElementVNode("span",null,f.toDisplayString(O.$t("bpmn.tempConfigTip")),1)]),default:f.withCtx(()=>[f.createVNode(be,{type:"link",onClick:Z=>w($),style:{"padding-left":"0"},disabled:!f.unref(s).includes($.id)},{default:f.withCtx(()=>F[4]||(F[4]=[f.createTextVNode(f.toDisplayString("配置渲染模版"))])),_:2},1032,["onClick","disabled"])]),_:2},1024)):f.createCommentVNode("",!0)]),_:1},8,["columns","row-selection"]),f.createVNode(ce,{class:"modal-btns"},{default:f.withCtx(()=>{var $;return[f.createVNode(be,{onClick:B},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(be,{type:"primary",disabled:!(($=f.unref(s))!=null&&$.length),onClick:L},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(O.$t("common.btn_sure")),1)]),_:1},8,["disabled"])]}),_:1})]),f.createVNode(Te,{open:f.unref(d),"onUpdate:open":F[3]||(F[3]=$=>f.isRef(d)?d.value=$:null),title:"配置渲染模版",onOk:y,onCancel:g},{default:f.withCtx(()=>[f.createVNode(ED,{data:f.unref(u),"onUpdate:data":F[2]||(F[2]=$=>f.isRef(u)?u.value=$:null),"template-list":f.unref(C)},null,8,["data","template-list"])]),_:1},8,["open"])],64)}}}),SD={class:"modal-container"},CD=f.defineComponent({__name:"SelectUser",props:{userIds:{type:String||Array},branchId:{type:String},mode:{type:String,default:"default"}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({}),a=f.ref([{title:n("user.user_name"),dataIndex:"userName"},{title:n("user.user_id"),dataIndex:"userCode"},{title:n("arrears.org"),dataIndex:"branchName"}]),s=f.ref([]),c=f.ref();function l(g,w){s.value=g,c.value=w}f.watchEffect(()=>{i.userIds&&(s.value=Array.isArray(i.userIds)?i.userIds:[i.userIds])});function u(g){c.value=null;const w={...o.value,branchId:i.branchId};return Object.assign(w,g),ct.getUserList(w)}const p=f.ref(),d=()=>{p.value.refresh()},h=()=>{o.value={},d()};f.onMounted(()=>{h()});function m(){Qe.Modal.destroyAll()}function y(){var g;if((g=c.value)!=null&&g.length){const w=c.value;r("submit",i.mode==="multiple"?w:w[0])}Qe.Modal.destroyAll()}return(g,w)=>{const C=U.Input,x=U.FormItem,b=U.Button,S=U.Space,P=U.Form,M=f.resolveComponent("a-table-ex");return f.openBlock(),f.createElementBlock("div",SD,[f.createVNode(P,{class:"form-query mx-nm mt-nm",layout:"vertical",model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(x,{label:g.$t("user.key")},{default:f.withCtx(()=>[f.createVNode(C,{value:f.unref(o).userName,"onUpdate:value":w[0]||(w[0]=R=>f.unref(o).userName=R),placeholder:g.$t("common.plsEnter"),onKeydown:f.withKeys(d,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(x,{class:"form-btns"},{default:f.withCtx(()=>[f.createVNode(S,null,{default:f.withCtx(()=>[f.createVNode(b,{type:"primary",onClick:d},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_search")),1)]),_:1}),f.createVNode(b,{onClick:h},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_reset")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),f.createVNode(M,{ref_key:"tableEx",ref:p,class:"table-query bordered mx-nm",columns:f.unref(a),rowKey:"userId","row-selection":{type:e.mode==="multiple"?"checkbox":"radio",selectedRowKeys:f.unref(s),onChange:l},loadData:u},null,8,["columns","row-selection"]),f.createVNode(S,{class:"modal-btns"},{default:f.withCtx(()=>{var R;return[f.createVNode(b,{onClick:m},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(b,{type:"primary",disabled:!((R=f.unref(s))!=null&&R.length),onClick:y},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_sure")),1)]),_:1},8,["disabled"])]}),_:1})])}}}),RD=f.defineComponent({__name:"UserTask",props:f.mergeModels({isApproval:{type:Boolean}},{formState:{},formStateModifiers:{}}),emits:["update:formState"],setup(e){const{modal:t}=Qe.App.useApp(),{t:n}=Zt.useI18n(),i=f.useModel(e,"formState"),r=f.ref(["1","2","3","4","5","6"]),o=f.ref([]),a=f.ref([]),s=f.ref([]),c=f.computed(()=>{const w=i.value.assignee;return w==null?void 0:w.startsWith("${")});function l(){const w="abcdefghijklmnopqrstuvwxyz";let C="";for(let x=0;x<2;x++)C+=w.charAt(Math.floor(Math.random()*w.length));for(let x=0;x<2;x++)C+=Math.floor(Math.random()*10);return C}function u(){t.info({title:n("link.select_link"),content:f.h(wD,{id:i.value.id,variable:i.value.assignee,description:i.value.name,componentInfo:i.value.bindComponent,onSubmit:w=>{let C=w.id;C.endsWith("*")&&(w.hasSuffix?C=C.substring(0,C.length-1)+w.hasSuffix:C=C.substring(0,C.length-1)+l()),Object.assign(i.value,{id:C,name:w.description,assignee:"","camunda:assigneeName":"",priority:void 0,userArr:[],roleArr:[]}),w.variable&&(i.value.assignee=`\${${w.variable}}`),w.bindComponent&&(i.value.bindComponent=w.bindComponent)}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:850,zIndex:100,class:"modal-comp"})}function p(){t.info({title:n("user.select_user"),content:f.h(CD,{userIds:i.value.assignee,onSubmit:w=>{Object.assign(i.value,{assignee:w.userId,"camunda:assigneeName":w.userName})}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:800,class:"modal-comp"})}function d(){ct.getBranchTree().then(w=>{w.code===0&&(o.value=w.result||[])})}function h(){const w={pageNo:1,pageSize:1e3,branchId:i.value.priority||void 0};ct.getUserList(w).then(C=>{var x,b;C.code===0&&(s.value=((b=(x=C.result)==null?void 0:x.data)==null?void 0:b.map(S=>({...S,label:S.userName,value:S.userId})))||[])})}function m(){const w={pageNo:1,pageSize:1e3,branchId:i.value.priority||void 0};ct.getRoleList(w).then(C=>{var x,b;C.code===0&&(a.value=((b=(x=C.result)==null?void 0:x.data)==null?void 0:b.map(S=>({...S,label:S.roleName,value:S.roleId})))||[])})}function y(){Object.assign(i.value,{userArr:[],roleArr:[]}),h(),m()}function g(w){if(w!=null&&w.length){const C=s.value.find(x=>x.userId===w[0]);i.value.priority!==C.branchId&&(Object.assign(i.value,{priority:C.branchId,roleArr:[]}),h(),m())}}return f.onMounted(()=>{d(),h(),m()}),(w,C)=>{const x=U.Input,b=U.FormItem,S=U.TreeSelect,P=U.Select,M=U.Form,R=U.CollapsePanel,I=U.Radio,B=U.RadioGroup,L=U.Checkbox,O=U.CheckboxGroup,F=U.Collapse;return f.openBlock(),f.createBlock(F,{activeKey:f.unref(r),"onUpdate:activeKey":C[10]||(C[10]=G=>f.isRef(r)?r.value=G:null)},{default:f.withCtx(()=>[f.createVNode(R,{key:"1",header:w.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(M,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(b,{label:w.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(x,{value:i.value.id,"onUpdate:value":C[0]||(C[0]=G=>i.value.id=G),placeholder:w.$t("common.plsEnter"),readonly:"",onClick:u},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(x,{value:i.value.name,"onUpdate:value":C[1]||(C[1]=G=>i.value.name=G),placeholder:w.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Assignee")},{default:f.withCtx(()=>[f.unref(c)?(f.openBlock(),f.createBlock(x,{key:0,value:i.value.assignee,"onUpdate:value":C[2]||(C[2]=G=>i.value.assignee=G),placeholder:w.$t("common.plsSelect"),disabled:""},null,8,["value","placeholder"])):(f.openBlock(),f.createBlock(x,{key:1,value:i.value["camunda:assigneeName"],"onUpdate:value":C[3]||(C[3]=G=>i.value["camunda:assigneeName"]=G),placeholder:w.$t("common.plsSelect"),readonly:"",onClick:p},null,8,["value","placeholder"]))]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Priority")},{default:f.withCtx(()=>[f.createVNode(S,{value:i.value.priority,"onUpdate:value":C[4]||(C[4]=G=>i.value.priority=G),placeholder:w.$t("common.plsSelect"),"tree-data":f.unref(o),treeDefaultExpandAll:"",treeNodeFilterProp:"label","show-search":"","allow-clear":"",onChange:y},null,8,["value","placeholder","tree-data"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Candidate Users")},{default:f.withCtx(()=>[f.createVNode(P,{value:i.value.userArr,"onUpdate:value":C[5]||(C[5]=G=>i.value.userArr=G),placeholder:w.$t("common.plsSelect"),mode:"multiple",maxTagCount:10,options:f.unref(s),optionFilterProp:"label",disabled:f.unref(c),onChange:g},null,8,["value","placeholder","options","disabled"])]),_:1},8,["label"]),f.createVNode(b,{label:w.$t("FLOW_CHART.Candidate Groups")},{default:f.withCtx(()=>[f.createVNode(P,{value:i.value.roleArr,"onUpdate:value":C[6]||(C[6]=G=>i.value.roleArr=G),placeholder:w.$t("common.plsSelect"),mode:"multiple",maxTagCount:10,options:f.unref(a),optionFilterProp:"label",disabled:f.unref(c)},null,8,["value","placeholder","options","disabled"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"]),e.isApproval?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(R,{key:"2",header:w.$t("FLOW_CHART.isAllowRollback")},{default:f.withCtx(()=>[f.createVNode(B,{value:i.value.rollback,"onUpdate:value":C[7]||(C[7]=G=>i.value.rollback=G)},{default:f.withCtx(()=>[f.createVNode(I,{value:"1"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.yes")),1)]),_:1}),f.createVNode(I,{value:"0"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.no")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["header"])),e.isApproval?(f.openBlock(),f.createBlock(R,{key:"3",header:w.$t("FLOW_CHART.Approval Mode")},{default:f.withCtx(()=>[f.createVNode(B,{value:i.value.approvalSign,"onUpdate:value":C[8]||(C[8]=G=>i.value.approvalSign=G)},{default:f.withCtx(()=>[f.createVNode(I,{value:"orSign"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.Or Sign")),1)]),_:1}),f.createVNode(I,{value:"countersign"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.countersign")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["header"])):f.createCommentVNode("",!0),e.isApproval?(f.openBlock(),f.createBlock(R,{key:"4",header:w.$t("FLOW_CHART.Approval Required")},{default:f.withCtx(()=>[f.createVNode(O,{value:i.value.approvalCheckbox,"onUpdate:value":C[9]||(C[9]=G=>i.value.approvalCheckbox=G)},{default:f.withCtx(()=>[f.createVNode(L,{value:"advice"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.Comments Required")),1)]),_:1}),f.createVNode(L,{value:"attachment"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(w.$t("FLOW_CHART.Attachment Required")),1)]),_:1})]),_:1},8,["value"])]),_:1},8,["header"])):f.createCommentVNode("",!0)]),_:1},8,["activeKey"])}}}),TD=f.defineComponent({__name:"ExclusiveGateway",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const t=f.useModel(e,"formState"),n=f.ref(["1","2","3","4","5","6"]);return(i,r)=>{const o=U.Input,a=U.FormItem,s=U.Form,c=U.CollapsePanel,l=U.Collapse;return f.openBlock(),f.createBlock(l,{activeKey:f.unref(n),"onUpdate:activeKey":r[2]||(r[2]=u=>f.isRef(n)?n.value=u:null)},{default:f.withCtx(()=>[f.createVNode(c,{key:"1",header:i.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(s,{layout:"vertical",model:t.value},{default:f.withCtx(()=>[f.createVNode(a,{label:i.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.id,"onUpdate:value":r[0]||(r[0]=u=>t.value.id=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.name,"onUpdate:value":r[1]||(r[1]=u=>t.value.name=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),PD=f.defineComponent({__name:"SequenceFlow",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const t=f.useModel(e,"formState"),n=f.ref(["1","2","3","4","5","6"]);return(i,r)=>{const o=U.Input,a=U.FormItem,s=U.SelectOption,c=U.Select,l=U.Form,u=U.CollapsePanel,p=U.Collapse;return f.openBlock(),f.createBlock(p,{activeKey:f.unref(n),"onUpdate:activeKey":r[4]||(r[4]=d=>f.isRef(n)?n.value=d:null)},{default:f.withCtx(()=>[f.createVNode(u,{key:"1",header:i.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(l,{layout:"vertical",model:t.value},{default:f.withCtx(()=>[f.createVNode(a,{label:i.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.id,"onUpdate:value":r[0]||(r[0]=d=>t.value.id=d),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.name,"onUpdate:value":r[1]||(r[1]=d=>t.value.name=d),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Condition Type")},{default:f.withCtx(()=>[f.createVNode(c,{value:t.value.condType,"onUpdate:value":r[2]||(r[2]=d=>t.value.condType=d),placeholder:i.$t("common.plsSelect"),allowClear:""},{default:f.withCtx(()=>[f.createVNode(s,{value:"bpmn:FormalExpression"},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(i.$t("FLOW_CHART.Expression")),1)]),_:1})]),_:1},8,["value","placeholder"])]),_:1},8,["label"]),t.value.condType==="bpmn:FormalExpression"?(f.openBlock(),f.createBlock(a,{key:0,label:i.$t("FLOW_CHART.Expression")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.condBody,"onUpdate:value":r[3]||(r[3]=d=>t.value.condBody=d),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])):f.createCommentVNode("",!0)]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),AD={class:"modal-container"},kD=f.defineComponent({__name:"SelectLink",props:{id:{type:String}},emits:["submit"],setup(e,{emit:t}){const{t:n}=Zt.useI18n(),i=e,r=t,o=f.ref({}),a=f.ref([{title:n("link.id"),dataIndex:"id"},{title:n("link.description"),dataIndex:"description"},{title:n("link.due"),dataIndex:"due"},{title:n("link.variable"),dataIndex:"variable"}]),s=f.ref([]),c=f.ref();function l(g,w){s.value=g,c.value=w}f.watchEffect(()=>{i.id&&(s.value=[i.id])});function u(g){c.value=null;const w={...o.value};return Object.assign(w,g),ct.getLinkList(w)}const p=f.ref(),d=()=>{p.value.refresh()},h=()=>{o.value={},d()};f.onMounted(()=>{h()});function m(){Qe.Modal.destroyAll()}function y(){var g;(g=c.value)!=null&&g.length&&r("submit",c.value[0]),Qe.Modal.destroyAll()}return(g,w)=>{const C=U.Input,x=U.FormItem,b=U.Button,S=U.Space,P=U.Form,M=f.resolveComponent("a-table-ex");return f.openBlock(),f.createElementBlock("div",AD,[f.createVNode(P,{class:"form-query mx-nm mt-nm",layout:"vertical",model:f.unref(o)},{default:f.withCtx(()=>[f.createVNode(x,{label:g.$t("link.id")},{default:f.withCtx(()=>[f.createVNode(C,{value:f.unref(o).id,"onUpdate:value":w[0]||(w[0]=R=>f.unref(o).id=R),placeholder:g.$t("common.plsEnter"),onKeydown:f.withKeys(d,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(x,{label:g.$t("link.description")},{default:f.withCtx(()=>[f.createVNode(C,{value:f.unref(o).description,"onUpdate:value":w[1]||(w[1]=R=>f.unref(o).description=R),placeholder:g.$t("common.plsEnter"),onKeydown:f.withKeys(d,["enter"])},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(x,{class:"form-btns"},{default:f.withCtx(()=>[f.createVNode(S,null,{default:f.withCtx(()=>[f.createVNode(b,{type:"primary",onClick:d},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_search")),1)]),_:1}),f.createVNode(b,{onClick:h},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_reset")),1)]),_:1})]),_:1})]),_:1})]),_:1},8,["model"]),f.createVNode(M,{ref_key:"tableEx",ref:p,class:"table-query bordered mx-nm",columns:f.unref(a),rowKey:"id","row-selection":{type:"radio",selectedRowKeys:f.unref(s),onChange:l},loadData:u},null,8,["columns","row-selection"]),f.createVNode(S,{class:"modal-btns"},{default:f.withCtx(()=>{var R;return[f.createVNode(b,{onClick:m},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_cancel1")),1)]),_:1}),f.createVNode(b,{type:"primary",disabled:!((R=f.unref(s))!=null&&R.length),onClick:y},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(g.$t("common.btn_sure")),1)]),_:1},8,["disabled"])]}),_:1})])}}}),MD=f.defineComponent({__name:"EndEvent",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const{modal:t}=Qe.App.useApp(),{t:n}=Zt.useI18n(),i=f.useModel(e,"formState"),r=f.ref(["1","2","3","4","5","6"]);function o(){const s="abcdefghijklmnopqrstuvwxyz";let c="";for(let l=0;l<2;l++)c+=s.charAt(Math.floor(Math.random()*s.length));for(let l=0;l<2;l++)c+=Math.floor(Math.random()*10);return c}function a(){t.info({title:n("link.select_link"),content:f.h(kD,{id:i.value.id,onSubmit:s=>{let c=s.id;c.endsWith("*")&&(c=c.substring(0,c.length-1)+o()),Object.assign(i.value,{id:c,name:s.description})}}),centered:!0,icon:null,footer:null,closable:!0,maskClosable:!0,width:800,class:"modal-comp"})}return(s,c)=>{const l=U.Input,u=U.FormItem,p=U.Form,d=U.CollapsePanel,h=U.Collapse;return f.openBlock(),f.createBlock(h,{activeKey:f.unref(r),"onUpdate:activeKey":c[2]||(c[2]=m=>f.isRef(r)?r.value=m:null)},{default:f.withCtx(()=>[f.createVNode(d,{key:"1",header:s.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(p,{layout:"vertical",model:i.value},{default:f.withCtx(()=>[f.createVNode(u,{label:s.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(l,{value:i.value.id,"onUpdate:value":c[0]||(c[0]=m=>i.value.id=m),placeholder:s.$t("common.plsEnter"),readonly:"",onClick:a},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(u,{label:s.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(l,{value:i.value.name,"onUpdate:value":c[1]||(c[1]=m=>i.value.name=m),placeholder:s.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),DD=f.defineComponent({__name:"Other",props:{formState:{},formStateModifiers:{}},emits:["update:formState"],setup(e){const t=f.useModel(e,"formState"),n=f.ref(["1","2","3","4","5","6"]);return(i,r)=>{const o=U.Input,a=U.FormItem,s=U.Form,c=U.CollapsePanel,l=U.Collapse;return f.openBlock(),f.createBlock(l,{activeKey:f.unref(n),"onUpdate:activeKey":r[2]||(r[2]=u=>f.isRef(n)?n.value=u:null)},{default:f.withCtx(()=>[f.createVNode(c,{key:"1",header:i.$t("FLOW_CHART.General")},{default:f.withCtx(()=>[f.createVNode(s,{layout:"vertical",model:t.value},{default:f.withCtx(()=>[f.createVNode(a,{label:i.$t("FLOW_CHART.Id")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.id,"onUpdate:value":r[0]||(r[0]=u=>t.value.id=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"]),f.createVNode(a,{label:i.$t("FLOW_CHART.Name")},{default:f.withCtx(()=>[f.createVNode(o,{value:t.value.name,"onUpdate:value":r[1]||(r[1]=u=>t.value.name=u),placeholder:i.$t("common.plsEnter")},null,8,["value","placeholder"])]),_:1},8,["label"])]),_:1},8,["model"])]),_:1},8,["header"])]),_:1},8,["activeKey"])}}}),ND={class:"properties-panel"},OD=bn(f.defineComponent({__name:"BpmnPropertiesPanel",props:{modeler:{type:an},isEdit:{type:Boolean},isApproval:{type:Boolean}},setup(e){const t=e,n=f.ref(""),i=f.ref({});let r,o,a;f.watch(()=>t.modeler,()=>{t.modeler&&(r=t.modeler,s())}),f.watch(i,(u,p)=>{u===p&&l()},{deep:!0});function s(){o=r.get("modeling"),r.on("element.click",u=>{c(u.element)}),r.on("selection.changed",u=>{if(u.newSelection.length)c(u.newSelection[0]);else{const p=r.get("canvas").getRootElement();c(p)}})}function c(u){if(!(u!=null&&u.businessObject)||a===u)return;a=u;const p=u.businessObject,d=p.$type;n.value="",f.nextTick(()=>{n.value=d});const h={...p.$attrs};Object.keys(p).forEach(m=>{const y=p[m];typeof y=="string"&&(h[m]=y)}),d==="bpmn:UserTask"?(Object.assign(h,{rollback:h["camunda:rollback"]==="1"?"1":"0",approvalCheckbox:[]}),Object.assign(h,{approvalSign:h["camunda:countersign"]==="true"?"countersign":"orSign",approvalCheckbox:[]}),h["camunda:advice"]==="true"&&h.approvalCheckbox.push("advice"),h["camunda:attachment"]==="true"&&h.approvalCheckbox.push("attachment"),h["camunda:bindComponent"]&&(h.bindComponent=h["camunda:bindComponent"]),h.userArr=(h.candidateUsers||"").split(",").filter(m=>m),h.roleArr=(h.candidateGroups||"").split(",").filter(m=>m)):d==="bpmn:SequenceFlow"&&p.conditionExpression&&Object.assign(h,{condType:p.conditionExpression.$type,condBody:p.conditionExpression.body}),i.value=h}function l(){var m,y;const u=i.value;function p(g){return g?"true":"false"}const d={id:u.id,name:u.name},h=n.value;if(h==="bpmn:Process")u.jobPriority&&Object.assign(d,{"camunda:jobPriority":u.jobPriority});else if(h==="bpmn:UserTask")Object.assign(d,{"camunda:orSign":p(u.approvalSign==="orSign"),"camunda:rollback":u.rollback==="1"?"1":"0","camunda:countersign":p(u.approvalSign==="countersign"),"camunda:advice":p(u.approvalCheckbox.includes("advice")),"camunda:attachment":p(u.approvalCheckbox.includes("attachment")),"camunda:assignee":u.assignee||void 0,"camunda:assigneeName":u["camunda:assigneeName"]||void 0,"camunda:priority":u.priority||void 0,"camunda:candidateUsers":((m=u.userArr)==null?void 0:m.join())||void 0,"camunda:candidateGroups":((y=u.roleArr)==null?void 0:y.join())||void 0,"camunda:bindComponent":u.bindComponent});else if(h==="bpmn:SequenceFlow")if(u.condType){const g=r.get("moddle").create("bpmn:FormalExpression",{body:u.condBody});d.conditionExpression=g}else d.conditionExpression=null;o.updateProperties(a,d)}return(u,p)=>{const d=tf;return f.openBlock(),f.createElementBlock("div",ND,[f.createVNode(d,null,{default:f.withCtx(()=>[f.unref(n)==="bpmn:Process"?(f.openBlock(),f.createBlock(bD,{key:0,formState:f.unref(i),"onUpdate:formState":p[0]||(p[0]=h=>f.isRef(i)?i.value=h:null),isEdit:e.isEdit},null,8,["formState","isEdit"])):f.unref(n)==="bpmn:UserTask"?(f.openBlock(),f.createBlock(RD,{key:1,formState:f.unref(i),"onUpdate:formState":p[1]||(p[1]=h=>f.isRef(i)?i.value=h:null),isApproval:e.isApproval},null,8,["formState","isApproval"])):f.unref(n)==="bpmn:ExclusiveGateway"?(f.openBlock(),f.createBlock(TD,{key:2,formState:f.unref(i),"onUpdate:formState":p[2]||(p[2]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.unref(n)==="bpmn:SequenceFlow"?(f.openBlock(),f.createBlock(PD,{key:3,formState:f.unref(i),"onUpdate:formState":p[3]||(p[3]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.unref(n)==="bpmn:EndEvent"?(f.openBlock(),f.createBlock(MD,{key:4,formState:f.unref(i),"onUpdate:formState":p[4]||(p[4]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.unref(n)?(f.openBlock(),f.createBlock(DD,{key:5,formState:f.unref(i),"onUpdate:formState":p[5]||(p[5]=h=>f.isRef(i)?i.value=h:null)},null,8,["formState"])):f.createCommentVNode("",!0)]),_:1})])}}}),[["__scopeId","data-v-31b3ee78"]]),ID={class:"wrapper"},BD=bn(f.defineComponent({__name:"index",props:{data:{type:Object,required:!0}},setup(e,{expose:t}){const n=e,i=f.shallowRef();function r(){i.value=new an({container:"#canvas",moddleExtensions:{camunda:lD}})}function o(){ct.getBpmnXml({code:n.data.code}).then(s=>{var c;if(s.code===0){const l=s.result.text;(c=i.value)==null||c.importXML(l)}})}f.onMounted(()=>{var s;r(),n.data.code?o():(s=i.value)==null||s.createDiagram()});function a(){var s;return(s=i.value)==null?void 0:s.saveXML({format:!0})}return t({saveXML:a}),(s,c)=>(f.openBlock(),f.createElementBlock("div",ID,[c[0]||(c[0]=f.createElementVNode("div",{id:"canvas"},null,-1)),f.createVNode(OD,{modeler:f.unref(i),isEdit:e.data.opType==="2",isApproval:e.data.isApproval},null,8,["modeler","isEdit","isApproval"])]))}}),[["__scopeId","data-v-5f499ed0"]]),LD={class:"icon",viewBox:"0 0 1024 1024",width:"1.2em",height:"1.2em"};function $D(e,t){return f.openBlock(),f.createElementBlock("svg",LD,t[0]||(t[0]=[f.createElementVNode("path",{fill:"currentColor",d:"M724 218.3V141c0-6.7-7.7-10.4-12.9-6.3L260.3 486.8a31.86 31.86 0 0 0 0 50.3l450.8 352.1c5.3 4.1 12.9.4 12.9-6.3v-77.3c0-4.9-2.3-9.6-6.1-12.6l-360-281l360-281.1c3.8-3 6.1-7.7 6.1-12.6"},null,-1)]))}const jD=f.markRaw({name:"ant-design-left",render:$D}),FD={class:"container"},HD={class:"viewer-container"},VD=bn(f.defineComponent({__name:"BpmnEditPage",props:{data:{type:Object,required:!0}},setup(e){const{t}=Zt.useI18n(),n=e,i=f.computed(()=>{const c=n.data.opType||"1";if(c==="1")return t("bpmn.add_workflow");if(c==="2")return t("bpmn.edit_workflow");if(c==="3")return t("bpmn.clone_workflow")}),r=f.inject(Ko);function o(){r==null||r.emit("changeComp",{comp:"BusTypeList"})}const a=f.ref();function s(){var c;(c=a.value)==null||c.saveXML().then(({error:l,xml:u})=>{if(l){Qe.message.error(l);return}const p={type:n.data.type,text:u};((n.data.opType||"1")==="2"?ct.bpmnUpdate(p):ct.bpmnInsert(p)).then(m=>{m.code===0&&(r==null||r.emit("changeComp",{comp:"BusTypeList"}))})})}return(c,l)=>{const u=jD,p=U.Button,d=U.Space,h=U.PageHeader,m=BD;return f.openBlock(),f.createElementBlock("div",FD,[f.createVNode(h,{class:"page-header-sticky",title:f.unref(i),onBack:o},{backIcon:f.withCtx(()=>[f.createVNode(u)]),extra:f.withCtx(()=>[f.createVNode(d,null,{default:f.withCtx(()=>[f.createVNode(p,{type:"default",onClick:o},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(c.$t("common.btn_cancel")),1)]),_:1}),f.createVNode(p,{type:"primary",onClick:s},{default:f.withCtx(()=>[f.createTextVNode(f.toDisplayString(c.$t("common.btn_ok")),1)]),_:1})]),_:1})]),_:1},8,["title"]),f.createElementVNode("div",HD,[f.createVNode(m,{ref_key:"bpmnViewer",ref:a,data:e.data},null,8,["data"])])])}}}),[["__scopeId","data-v-e763e4dc"]]),zD={class:"wrapper"},WD=bn(f.defineComponent({components:{BusTypeList:EE,BpmnEditPage:VD},__name:"index",setup(e){const t=f.ref("BusTypeList"),n=f.ref(),i=M_(Ko);return f.provide(Ko,i),i.on((r,o)=>{r==="changeComp"&&(t.value=o.comp,n.value=o)}),(r,o)=>{const a=I_;return f.openBlock(),f.createBlock(a,null,{default:f.withCtx(()=>[f.createElementVNode("div",zD,[(f.openBlock(),f.createBlock(f.KeepAlive,{include:"BusTypeList"},[(f.openBlock(),f.createBlock(f.resolveDynamicComponent(f.unref(t)),{data:f.unref(n)},null,8,["data"]))],1024))])]),_:1})}}}),[["__scopeId","data-v-82fb5b00"]]);_p.createPinia();function UD(e){ic().setLang(e)}function GD(e,t){const{i18n:n,pinia:i,theme:r}=t;u_(n);const o=ic();o.setTheme(r),o.setupLangWatcher()}const KD={install:GD};bt.WfManagePage=WD,bt.default=KD,bt.setWorkflowLang=UD,Object.defineProperties(bt,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}})});
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@witlink/workflow",
3
3
  "private": false,
4
- "version": "1.0.12",
4
+ "version": "1.0.13",
5
5
  "description": "witlink工作流",
6
6
  "license": "MIT",
7
7
  "type": "module",