MerchantBaseInfo-ca187be0.js 8.9 KB

1
  1. import{d as R,Y,K as Z,h as C,r as f,e as D,l as G,L as H,b9 as L,aP as J,x as Q,a,o as m,v as b,w as l,f as e,P,c as T,g as W,Z as X,V as $,A as ee,E as le,y as ae,z as te,i as se,ba as de,B as re,D as oe,I as ue,_ as ie,__tla as ne}from"./index-8e30b17f.js";import{_ as pe,__tla as me}from"./Editor-ea1788e9.js";import{_ as ce,__tla as _e}from"./UploadImg-1c51a097.js";import{g as fe,__tla as be}from"./index-eb323ef8.js";import{d as Ve}from"./tree-0af4953a.js";import{u as ve,__tla as ge}from"./useMessage-ee50bd51.js";import{__tla as ye}from"./index-7d9ab767.js";import{__tla as he}from"./el-image-viewer-fb97741c.js";let q,we=Promise.all([(()=>{try{return ne}catch{}})(),(()=>{try{return me}catch{}})(),(()=>{try{return _e}catch{}})(),(()=>{try{return be}catch{}})(),(()=>{try{return ge}catch{}})(),(()=>{try{return ye}catch{}})(),(()=>{try{return he}catch{}})()]).then(async()=>{let V,v,g;V={key:0},v=["innerHTML"],g={key:1},q=ie(R({__name:"MerchantBaseInfo",props:{id:{type:Number,default:0},isDetail:{type:Boolean,default:!1},openType:{type:String,default:"\u67E5\u770B"},propFormData:{type:Object,default:()=>{}}},emits:["update:activeName"],setup(n,{expose:I,emit:N}){const S=Y(),y=Z(()=>S.getMobile),k=ve();C();const M=f(!1),t=D({id:void 0,name:void 0,status:void 0,description:void 0,contact:void 0,address:void 0,contactNumber:void 0,website:void 0,createTime:void 0,complaintsHotline:void 0,customerServiceHotline:void 0,email:void 0,businessLicensePicture:void 0,expireTime:void 0,areaId:void 0}),B=D({name:[{required:!0,message:"\u5546\u6237\u540D\u79F0\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],description:[{required:!0,message:"\u7B80\u4ECB\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],contact:[{required:!0,message:"\u8D1F\u8D23\u4EBA\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],address:[{required:!0,message:"\u529E\u516C\u5730\u5740\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],contactNumber:[{required:!0,message:"\u8D1F\u8D23\u4EBA\u7535\u8BDD\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],complaintsHotline:[{required:!0,message:"\u7EF4\u6743\u7535\u8BDD\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],areaId:[{required:!0,message:"\u6240\u5728\u5730\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],customerServiceHotline:[{required:!0,message:"\u5BA2\u670D\u7535\u8BDD\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],email:[{required:!0,message:"\u90AE\u7BB1\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}],businessLicensePicture:[{required:!0,message:"\u8425\u4E1A\u6267\u7167\u4E0D\u80FD\u4E3A\u7A7A",trigger:"blur"}]}),c=f(),h=n,w=f([]);G(async()=>{w.value=await fe()}),H(()=>h.propFormData,p=>{p&&L(t,p)},{immediate:!0});const F=N;I({validate:async()=>{var p;if(c)try{return await((p=a(c))==null?void 0:p.validate()),Object.assign(h.propFormData,t),!0}catch{return k.error("\u57FA\u672C\u4FE1\u606F\u4E0D\u5B8C\u5584\uFF0C\u8BF7\u586B\u5199\u76F8\u5173\u4FE1\u606F"),F("update:activeName","info"),!1}}});const z=J("updateInitialData");return H(t,p=>{try{L(z.value,t)}catch{}},{immediate:!0}),(p,s)=>{const i=$,r=ee,o=le,_=ae,j=te,u=se,E=de,U=re,x=ce,O=pe,A=oe,K=ue;return Q((m(),b(A,{ref_key:"formRef",ref:c,model:a(t),class:X([{view:n.isDetail,"mobile-card":a(y)},"overflow-auto"]),rules:a(B),"label-width":"120px",disabled:n.isDetail,style:{overflow:"hidden"}},{default:l(()=>[e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{label:"\u5546\u6237\u540D\u79F0",prop:"name"},{default:l(()=>[e(i,{modelValue:a(t).name,"onUpdate:modelValue":s[0]||(s[0]=d=>a(t).name=d),placeholder:"\u8BF7\u8F93\u5165\u5546\u6237\u540D\u79F0"},null,8,["modelValue"])]),_:1})]),_:1}),n.openType!="\u65B0\u589E"?(m(),b(o,{key:0,span:12},{default:l(()=>[e(r,{label:"\u72B6\u6001",prop:"status"},{default:l(()=>[e(j,{modelValue:a(t).status,"onUpdate:modelValue":s[1]||(s[1]=d=>a(t).status=d),placeholder:"\u8BF7\u9009\u62E9\u5546\u6237\u72B6\u6001",class:"w-1/1",clearable:""},{default:l(()=>[e(_,{label:"\u4F7F\u7528\u4E2D",value:10}),e(_,{label:"\u8FC7\u671F",value:20}),e(_,{label:"\u505C\u7528",value:30})]),_:1},8,["modelValue"])]),_:1})]),_:1})):P("",!0)]),_:1}),e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{label:"\u8D1F\u8D23\u4EBA",prop:"contact"},{default:l(()=>[e(i,{modelValue:a(t).contact,"onUpdate:modelValue":s[2]||(s[2]=d=>a(t).contact=d),placeholder:"\u8BF7\u8F93\u5165\u8D1F\u8D23\u4EBA"},null,8,["modelValue"])]),_:1})]),_:1}),e(o,{span:12},{default:l(()=>[e(r,{label:"\u6240\u5728\u5730",prop:"areaId"},{default:l(()=>[e(E,{modelValue:a(t).areaId,"onUpdate:modelValue":s[3]||(s[3]=d=>a(t).areaId=d),options:a(w),props:a(Ve),class:"w-1/1",clearable:"",placeholder:"\u8BF7\u9009\u62E9\u6240\u5728\u5730",filterable:"","collapse-tags":""},null,8,["modelValue","options","props"])]),_:1})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{label:"\u8D1F\u8D23\u4EBA\u624B\u673A\u53F7",prop:"contactNumber"},{default:l(()=>[e(i,{modelValue:a(t).contactNumber,"onUpdate:modelValue":s[4]||(s[4]=d=>a(t).contactNumber=d),placeholder:"\u8BF7\u8F93\u5165\u8D1F\u8D23\u4EBA\u624B\u673A\u53F7"},null,8,["modelValue"])]),_:1})]),_:1}),e(o,{span:12},{default:l(()=>[e(r,{label:"\u90AE\u7BB1",prop:"email"},{default:l(()=>[e(i,{modelValue:a(t).email,"onUpdate:modelValue":s[5]||(s[5]=d=>a(t).email=d),placeholder:"\u8BF7\u8F93\u5165\u90AE\u7BB1"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{label:"\u6807\u7B7E"},{default:l(()=>[e(i,{disabled:""})]),_:1})]),_:1}),e(o,{span:12},{default:l(()=>[e(r,{label:"\u529E\u516C\u5730\u5740",prop:"address"},{default:l(()=>[e(i,{modelValue:a(t).address,"onUpdate:modelValue":s[6]||(s[6]=d=>a(t).address=d),placeholder:"\u8BF7\u8F93\u5165\u529E\u516C\u5730\u5740"},null,8,["modelValue"])]),_:1})]),_:1}),e(o,{span:12,style:{display:"none"}},{default:l(()=>[e(r,{label:"\u670D\u52A1\u5230\u671F\u65F6\u95F4",prop:"expireTime"},{default:l(()=>[e(U,{modelValue:a(t).expireTime,"onUpdate:modelValue":s[7]||(s[7]=d=>a(t).expireTime=d),type:"date","value-format":"x",placeholder:"\u9009\u62E9\u670D\u52A1\u5230\u671F\u65F6\u95F4"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{label:"\u7EF4\u6743\u7535\u8BDD",prop:"complaintsHotline"},{default:l(()=>[e(i,{modelValue:a(t).complaintsHotline,"onUpdate:modelValue":s[8]||(s[8]=d=>a(t).complaintsHotline=d),placeholder:"\u8BF7\u8F93\u5165\u7EF4\u6743\u7535\u8BDD"},null,8,["modelValue"])]),_:1})]),_:1}),e(o,{span:12},{default:l(()=>[e(r,{label:"\u5BA2\u670D\u7535\u8BDD",prop:"customerServiceHotline"},{default:l(()=>[e(i,{modelValue:a(t).customerServiceHotline,"onUpdate:modelValue":s[9]||(s[9]=d=>a(t).customerServiceHotline=d),placeholder:"\u8BF7\u8F93\u5165\u5BA2\u670D\u7535\u8BDD"},null,8,["modelValue"])]),_:1})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{label:"\u5B98\u7F51",prop:"website"},{default:l(()=>[e(i,{modelValue:a(t).website,"onUpdate:modelValue":s[10]||(s[10]=d=>a(t).website=d),placeholder:"\u8BF7\u8F93\u5165\u5B98\u7F51"},null,8,["modelValue"])]),_:1})]),_:1}),n.isDetail?(m(),b(o,{key:0,span:12},{default:l(()=>[e(r,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"customerServiceHotline"},{default:l(()=>[e(U,{modelValue:a(t).createTime,"onUpdate:modelValue":s[11]||(s[11]=d=>a(t).createTime=d),type:"date","value-format":"x",disabled:""},null,8,["modelValue"])]),_:1})]),_:1})):P("",!0)]),_:1}),a(y)?(m(),T("div",V,[e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{style:{border:"none"},label:"\u8425\u4E1A\u6267\u7167",prop:"businessLicensePicture"})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:24},{default:l(()=>[e(r,{prop:"businessLicensePicture",class:"businessLicensePicture"},{default:l(()=>[e(x,{modelValue:a(t).businessLicensePicture,"onUpdate:modelValue":s[12]||(s[12]=d=>a(t).businessLicensePicture=d),limit:1,disabled:n.isDetail},null,8,["modelValue","disabled"])]),_:1})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:12},{default:l(()=>[e(r,{style:{border:"none"},label:"\u7B80\u4ECB",prop:"description"})]),_:1})]),_:1}),e(o,{span:24},{default:l(()=>[e(r,{prop:"description",class:"description"},{default:l(()=>[W("div",{innerHTML:a(t).description},null,8,v)]),_:1})]),_:1})])):(m(),T("div",g,[e(u,null,{default:l(()=>[e(o,{span:24},{default:l(()=>[e(r,{label:"\u8425\u4E1A\u6267\u7167",prop:"businessLicensePicture"},{default:l(()=>[e(x,{modelValue:a(t).businessLicensePicture,"onUpdate:modelValue":s[13]||(s[13]=d=>a(t).businessLicensePicture=d),limit:1,disabled:n.isDetail},null,8,["modelValue","disabled"])]),_:1})]),_:1})]),_:1}),e(u,null,{default:l(()=>[e(o,{span:24},{default:l(()=>[e(r,{label:"\u7B80\u4ECB",prop:"description"},{default:l(()=>[e(O,{modelValue:a(t).description,"onUpdate:modelValue":s[14]||(s[14]=d=>a(t).description=d),height:"150px",disabled:n.isDetail},null,8,["modelValue","disabled"])]),_:1})]),_:1})]),_:1})]))]),_:1},8,["model","class","rules","disabled"])),[[K,a(M)]])}}}),[["__scopeId","data-v-1bd3a768"],["__file","D:/zx/mall-newfeifan-zx-admin/src/views/system/sale/merchant/components/MerchantBaseInfo.vue"]])});export{we as __tla,q as default};