1 |
- import{d as D,h as H,r as m,e as L,o as c,x as p,w as s,f as r,a as e,y as f,z as O,c as T,F as G,v as K,t as P,l as j,g as I,R as W,C as X,bw as J,ad as Q,ae as Y,H as Z,G as $,K as ee,_ as ae,__tla as le}from"./index-8dc1e40a.js";import{_ as te,__tla as se}from"./Dialog-41802231.js";import{_ as re,__tla as oe}from"./UploadImg-c2c75279.js";import{a as ue,D as de,__tla as me}from"./dict-f13a3c8f.js";import{C as x}from"./constants-a1da293a.js";import{a as ie,c as _e,u as ce,__tla as ne}from"./index-d527b348.js";import{u as pe,__tla as fe}from"./useMessage-7a27dd80.js";import{__tla as ve}from"./index-519182c1.js";import{__tla as ge}from"./el-image-viewer-3b8905e6.js";let w,ye=Promise.all([(()=>{try{return le}catch{}})(),(()=>{try{return se}catch{}})(),(()=>{try{return oe}catch{}})(),(()=>{try{return me}catch{}})(),(()=>{try{return ne}catch{}})(),(()=>{try{return fe}catch{}})(),(()=>{try{return ve}catch{}})(),(()=>{try{return ge}catch{}})()]).then(async()=>{let v;v=I("div",{style:{"font-size":"10px"},class:"pl-10px"},"\u63A8\u8350 180x180 \u56FE\u7247\u5206\u8FA8\u7387",-1),w=ae(D({name:"ExpressForm",__name:"ExpressForm",emits:["success"],setup(Ve,{expose:U,emit:E}){const{t:n}=H(),g=pe(),u=m(!1),y=m(""),d=m(!1),V=m(""),t=m({id:void 0,code:"",name:"",logo:"",sort:0,status:x.ENABLE}),F=L({code:[{required:!0,message:"\u5FEB\u9012\u7F16\u7801\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],name:[{required:!0,message:"\u5206\u7C7B\u540D\u79F0\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],logo:[{required:!0,message:"\u5206\u7C7B\u56FE\u7247\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],sort:[{required:!0,message:"\u5206\u7C7B\u6392\u5E8F\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],status:[{required:!0,message:"\u5F00\u542F\u72B6\u6001\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}]}),_=m();U({open:async(o,a)=>{if(u.value=!0,y.value=n("action."+o),V.value=o,C(),a){d.value=!0;try{t.value=await ie(a)}finally{d.value=!1}}}});const k=E,q=async()=>{if(_&&await _.value.validate()){d.value=!0;try{const o=t.value;V.value==="create"?(await _e(o),g.success(n("common.createSuccess"))):(await ce(o),g.success(n("common.updateSuccess"))),u.value=!1,k("success")}finally{d.value=!1}}},C=()=>{var o;t.value={id:void 0,name:"",picUrl:"",status:x.ENABLE},(o=_.value)==null||o.resetFields()};return(o,a)=>{const b=W,i=X,S=re,z=J,A=Q,M=Y,R=Z,h=$,N=te,B=ee;return c(),p(N,{title:e(y),modelValue:e(u),"onUpdate:modelValue":a[6]||(a[6]=l=>j(u)?u.value=l:null)},{footer:s(()=>[r(h,{onClick:q,type:"primary",disabled:e(d)},{default:s(()=>[f("\u786E \u5B9A")]),_:1},8,["disabled"]),r(h,{onClick:a[5]||(a[5]=l=>u.value=!1)},{default:s(()=>[f("\u53D6 \u6D88")]),_:1})]),default:s(()=>[O((c(),p(R,{ref_key:"formRef",ref:_,model:e(t),rules:e(F),"label-width":"120px"},{default:s(()=>[r(i,{label:"\u516C\u53F8\u7F16\u7801",prop:"code"},{default:s(()=>[r(b,{modelValue:e(t).code,"onUpdate:modelValue":a[0]||(a[0]=l=>e(t).code=l),placeholder:"\u8BF7\u8F93\u5165\u5FEB\u9012\u7F16\u7801"},null,8,["modelValue"])]),_:1}),r(i,{label:"\u516C\u53F8\u540D\u79F0",prop:"name"},{default:s(()=>[r(b,{modelValue:e(t).name,"onUpdate:modelValue":a[1]||(a[1]=l=>e(t).name=l),placeholder:"\u8BF7\u8F93\u5165\u5FEB\u9012\u540D\u79F0"},null,8,["modelValue"])]),_:1}),r(i,{label:"\u516C\u53F8 logo",prop:"logo"},{default:s(()=>[r(S,{modelValue:e(t).logo,"onUpdate:modelValue":a[2]||(a[2]=l=>e(t).logo=l),limit:1,"is-show-tip":!1},null,8,["modelValue"]),v]),_:1}),r(i,{label:"\u6392\u5E8F",prop:"sort"},{default:s(()=>[r(z,{modelValue:e(t).sort,"onUpdate:modelValue":a[3]||(a[3]=l=>e(t).sort=l),"controls-position":"right",min:0},null,8,["modelValue"])]),_:1}),r(i,{label:"\u5F00\u542F\u72B6\u6001",prop:"status"},{default:s(()=>[r(M,{modelValue:e(t).status,"onUpdate:modelValue":a[4]||(a[4]=l=>e(t).status=l)},{default:s(()=>[(c(!0),T(G,null,K(e(ue)(e(de).COMMON_STATUS),l=>(c(),p(A,{key:l.value,label:l.value},{default:s(()=>[f(P(l.label),1)]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue"])]),_:1})]),_:1},8,["model","rules"])),[[B,e(d)]])]),_:1},8,["title","modelValue"])}}}),[["__file","/Users/RuHu.Xu/Desktop/mall-newfeifan-zx-admin/src/views/mall/trade/delivery/express/ExpressForm.vue"]])});export{ye as __tla,w as default};
|