import{d as j,ah as A,Z as L,K as N,r as n,e as v,L as O,l as U,o as r,v as o,w as d,a as e,$ as Y,D as M,f as p,c as f,q as b,n as Q,t as q,F as D,Q as B,b9 as K,ae as X,bc as Z,A as $,y as C,z as G,_ as H,__tla as J}from"./index-04f8d540.js";import{g as W,__tla as ee}from"./index-bddac7e3.js";import{a as ae,D as le,__tla as te}from"./dict-ef06f7f7.js";import{D as se}from"./constants-40f13f5e.js";import{u as re,__tla as de}from"./useMessage-9c37e840.js";import{r as T,__tla as oe}from"./formRules-ba5d484c.js";let h,ie=Promise.all([(()=>{try{return J}catch{}})(),(()=>{try{return ee}catch{}})(),(()=>{try{return te}catch{}})(),(()=>{try{return de}catch{}})(),(()=>{try{return oe}catch{}})()]).then(async()=>{h=H(j({name:"ProductDeliveryForm",__name:"DeliveryForm",props:{propFormData:{type:Object,default:()=>{}},isDetail:A.bool.def(!1)},emits:["update:activeName"],setup(i,{expose:w,emit:F}){const I=L(),V=N(()=>I.getMobile),E=re(),_=i,m=n(),l=v({deliveryTypes:[],deliveryTemplateId:void 0}),x=v({deliveryTypes:[T],deliveryTemplateId:[T]});O(()=>_.propFormData,t=>{t&&K(l,t)},{immediate:!0});const k=F;w({validate:async()=>{var t;if(m)try{await((t=e(m))==null?void 0:t.validate()),Object.assign(_.propFormData,l)}catch(s){throw E.error("\u3010\u7269\u6D41\u8BBE\u7F6E\u3011\u4E0D\u5B8C\u5584\uFF0C\u8BF7\u586B\u5199\u76F8\u5173\u4FE1\u606F"),k("update:activeName","delivery"),s}}});const u=n([]);return U(async()=>{u.value=await W()}),(t,s)=>{const P=X,R=Z,c=$,g=C,z=G,S=M;return r(),o(S,{ref_key:"formRef",ref:m,model:e(l),rules:e(x),"label-width":"120px",disabled:i.isDetail,class:Y(["noBorder",{view:i.isDetail,"mobile-card":e(V)}])},{default:d(()=>{var y;return[p(c,{label:"\u914D\u9001\u65B9\u5F0F",prop:"deliveryTypes"},{default:d(()=>[p(R,{modelValue:e(l).deliveryTypes,"onUpdate:modelValue":s[0]||(s[0]=a=>e(l).deliveryTypes=a),class:"w-80"},{default:d(()=>[(r(!0),f(D,null,b(e(ae)(e(le).TRADE_DELIVERY_TYPE),a=>(r(),o(P,{key:a.value,label:a.value},{default:d(()=>[Q(q(a.label),1)]),_:2},1032,["label"]))),128))]),_:1},8,["modelValue"])]),_:1}),(y=e(l).deliveryTypes)!=null&&y.includes(e(se).EXPRESS.type)?(r(),o(c,{key:0,label:"\u8FD0\u8D39\u6A21\u677F",prop:"deliveryTemplateId"},{default:d(()=>[p(z,{placeholder:"\u8BF7\u9009\u62E9\u8FD0\u8D39\u6A21\u677F",modelValue:e(l).deliveryTemplateId,"onUpdate:modelValue":s[1]||(s[1]=a=>e(l).deliveryTemplateId=a),class:"w-80"},{default:d(()=>[(r(!0),f(D,null,b(e(u),a=>(r(),o(g,{key:a.id,label:a.name,value:a.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})):B("",!0)]}),_:1},8,["model","rules","disabled","class"])}}}),[["__scopeId","data-v-75cf19f9"],["__file","D:/zx/mall-newfeifan-zx-business/src/views/mall/product/spu/form/DeliveryForm.vue"]])});export{ie as __tla,h as default};
