import{_ as B,__tla as F}from"./Dialog-bbfaf85c.js";import{d as M,u as N,J as j,r as _,e as H,l as J,o as p,c as V,f as e,w as l,a as t,n,F as b,q as L,v as P,t as X,O as G,h as I,j as K,C as Q,V as W,A as Y,ah as Z,ai as $,D as aa,_ as ea,__tla as ta}from"./index-11e4820e.js";import{_ as la,__tla as ra}from"./ContentWrap-694014d4.js";import{a as sa,D as ua,__tla as oa}from"./dict-4072dcec.js";import{C as _a}from"./constants-40f13f5e.js";import{g as ma,c as na,u as da,__tla as ia}from"./index-f0a85a76.js";import{E as ca,__tla as fa}from"./index.es-88ea3b5c.js";import{s as pa,e as ya,a as ha}from"./formCreate-a3356cdc.js";import{u as va,__tla as Va}from"./tagsView-4d7a359f.js";import{u as ba,__tla as ka}from"./useMessage-06ddf735.js";import{__tla as ga}from"./ContentWrap.vue_vue_type_script_setup_true_lang-11f85821.js";import{__tla as wa}from"./el-card-919c14be.js";let k,xa=Promise.all([(()=>{try{return F}catch{}})(),(()=>{try{return ta}catch{}})(),(()=>{try{return ra}catch{}})(),(()=>{try{return oa}catch{}})(),(()=>{try{return ia}catch{}})(),(()=>{try{return fa}catch{}})(),(()=>{try{return Va}catch{}})(),(()=>{try{return ka}catch{}})(),(()=>{try{return ga}catch{}})(),(()=>{try{return wa}catch{}})()]).then(async()=>{k=ea(M({name:"BpmFormEditor",__name:"index",setup(Ca){const{t:y}=I(),h=ba(),{push:g,currentRoute:w}=N(),{query:x}=j(),{delView:C}=va(),m=_(),o=_(!1),d=_(!1),s=_({name:"",status:_a.ENABLE,remark:""}),U=H({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"}]}),i=_(),E=()=>{o.value=!0},S=async()=>{if(i&&await i.value.validate()){d.value=!0;try{const u=s.value;u.conf=ya(m),u.fields=ha(m),u.id?(await da(u),h.success(y("common.updateSuccess"))):(await na(u),h.success(y("common.createSuccess"))),o.value=!1,q()}finally{d.value=!1}}},q=()=>{C(t(w)),g("/bpm/manager/form")};return J(async()=>{const u=x.id;if(!u)return;const a=await ma(u);s.value=a,pa(m,a.conf,a.fields)}),(u,a)=>{const D=K,c=Q,A=la,v=W,f=Y,O=Z,R=$,T=aa,z=B;return p(),V(b,null,[e(A,null,{default:l(()=>[e(t(ca),{ref_key:"designer",ref:m,height:"780px"},{handle:l(()=>[e(c,{round:"",size:"small",type:"primary",onClick:E},{default:l(()=>[e(D,{class:"mr-5px",icon:"ep:plus"}),n(" \u4FDD\u5B58 ")]),_:1})]),_:1},512)]),_:1}),e(z,{modelValue:t(o),"onUpdate:modelValue":a[4]||(a[4]=r=>G(o)?o.value=r:null),title:"\u4FDD\u5B58\u8868\u5355",width:"600"},{footer:l(()=>[e(c,{disabled:t(d),type:"primary",onClick:S},{default:l(()=>[n("\u786E \u5B9A")]),_:1},8,["disabled"]),e(c,{onClick:a[3]||(a[3]=r=>o.value=!1)},{default:l(()=>[n("\u53D6 \u6D88")]),_:1})]),default:l(()=>[e(T,{ref_key:"formRef",ref:i,model:t(s),rules:t(U),"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(R,{modelValue:t(s).status,"onUpdate:modelValue":a[1]||(a[1]=r=>t(s).status=r)},{default:l(()=>[(p(!0),V(b,null,L(t(sa)(t(ua).COMMON_STATUS),r=>(p(),P(O,{key:r.value,label:r.value},{default:l(()=>[n(X(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)}}}),[["__file","/Users/RuHu.Xu/Desktop/mall-newfeifan-zx-admin/src/views/bpm/form/editor/index.vue"]])});export{xa as __tla,k as default};