index-021e1911.js 3.5 KB

1
  1. import{_ as O,__tla as T}from"./Dialog-4d17ac25.js";import{d as z,u as D,$ as G,r as _,x as K,b as L,o as p,c as b,f as e,B as l,a as t,E as n,F as v,R as P,A as Q,G as W,a2 as $,Q as j,_ as H,K as I,a8 as J,V as X,as as Y,at as Z,W as aa,__tla as ea}from"./index-e8bff8cb.js";import{_ as ta,__tla as la}from"./ContentWrap.vue_vue_type_script_setup_true_lang-33dea697.js";import{a as ra,D as sa,__tla as ua}from"./dict-4a54e490.js";import{C as oa}from"./constants-c811e5ff.js";import{g as _a,c as ma,u as na,__tla as da}from"./index-a83fb35f.js";import{E as ca,__tla as ia}from"./index.es-d0d2c2c0.js";import{s as fa,e as pa,a as ya}from"./formCreate-a3356cdc.js";import{u as ha,__tla as Va}from"./tagsView-a1cbfa1f.js";import{u as ba,__tla as va}from"./useMessage-de42a595.js";import"./_plugin-vue_export-helper-1b428a4d.js";import{__tla as ga}from"./el-card-f9558d99.js";let g,ka=Promise.all([(()=>{try{return T}catch{}})(),(()=>{try{return ea}catch{}})(),(()=>{try{return la}catch{}})(),(()=>{try{return ua}catch{}})(),(()=>{try{return da}catch{}})(),(()=>{try{return ia}catch{}})(),(()=>{try{return Va}catch{}})(),(()=>{try{return va}catch{}})(),(()=>{try{return ga}catch{}})()]).then(async()=>{g=z({name:"BpmFormEditor",__name:"index",setup(wa){const{t:y}=j(),h=ba(),{push:k,currentRoute:w}=D(),{query:x}=G(),{delView:C}=ha(),m=_(),o=_(!1),d=_(!1),s=_({name:"",status:oa.ENABLE,remark:""}),E=K({name:[{required:!0,message:"\u8868\u5355\u540D\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],status:[{required:!0,message:"\u5F00\u542F\u72B6\u6001\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}]}),c=_(),S=()=>{o.value=!0},U=async()=>{if(c&&await c.value.validate()){d.value=!0;try{const u=s.value;u.conf=pa(m),u.fields=ya(m),u.id?(await na(u),h.success(y("common.updateSuccess"))):(await ma(u),h.success(y("common.createSuccess"))),o.value=!1,q()}finally{d.value=!1}}},q=()=>{C(t(w)),k("/bpm/manager/form")};return L(async()=>{const u=x.id;if(!u)return;const a=await _a(u);s.value=a,fa(m,a.conf,a.fields)}),(u,a)=>{const B=H,i=I,R=ta,V=J,f=X,A=Y,N=Z,F=aa,M=O;return p(),b(v,null,[e(R,null,{default:l(()=>[e(t(ca),{ref_key:"designer",ref:m,height:"780px"},{handle:l(()=>[e(i,{round:"",size:"small",type:"primary",onClick:S},{default:l(()=>[e(B,{class:"mr-5px",icon:"ep:plus"}),n(" \u4FDD\u5B58 ")]),_:1})]),_:1},512)]),_:1}),e(M,{modelValue:t(o),"onUpdate:modelValue":a[4]||(a[4]=r=>$(o)?o.value=r:null),title:"\u4FDD\u5B58\u8868\u5355",width:"600"},{footer:l(()=>[e(i,{disabled:t(d),type:"primary",onClick:U},{default:l(()=>[n("\u786E \u5B9A")]),_:1},8,["disabled"]),e(i,{onClick:a[3]||(a[3]=r=>o.value=!1)},{default:l(()=>[n("\u53D6 \u6D88")]),_:1})]),default:l(()=>[e(F,{ref_key:"formRef",ref:c,model:t(s),rules:t(E),"label-width":"80px"},{default:l(()=>[e(f,{label:"\u8868\u5355\u540D",prop:"name"},{default:l(()=>[e(V,{modelValue:t(s).name,"onUpdate:modelValue":a[0]||(a[0]=r=>t(s).name=r),placeholder:"\u8BF7\u8F93\u5165\u8868\u5355\u540D"},null,8,["modelValue"])]),_:1}),e(f,{label:"\u72B6\u6001",prop:"status"},{default:l(()=>[e(N,{modelValue:t(s).status,"onUpdate:modelValue":a[1]||(a[1]=r=>t(s).status=r)},{default:l(()=>[(p(!0),b(v,null,P(t(ra)(t(sa).COMMON_STATUS),r=>(p(),Q(A,{key:r.value,label:r.value},{default:l(()=>[n(W(r.label),1)]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue"])]),_:1}),e(f,{label:"\u5907\u6CE8",prop:"remark"},{default:l(()=>[e(V,{modelValue:t(s).remark,"onUpdate:modelValue":a[2]||(a[2]=r=>t(s).remark=r),placeholder:"\u8BF7\u8F93\u5165\u5907\u6CE8",type:"textarea"},null,8,["modelValue"])]),_:1})]),_:1},8,["model","rules"])]),_:1},8,["modelValue"])],64)}}})});export{ka as __tla,g as default};