1 |
- import{_ as Je,__tla as Qe}from"./ContentWrap-2a772ce5.js";import{_ as Xe,__tla as Ge}from"./index-eead3ef4.js";import{d as We,u as Ze,Y as $e,K as ea,r as i,bQ as aa,h as ta,e as la,l as na,Q as oa,o as _,c as C,f as l,w as o,g as r,a,v as S,O as He,P as I,dF as sa,x as P,n as Y,R as w,a4 as X,F as G,q as Ne,t as y,b3 as Ae,e1 as Pe,W as ra,X as ia,C as ca,j as ma,V as da,A as ua,B as pa,E as ha,i as _a,D as va,aM as fa,p as ya,k as ga,_ as wa,__tla as ba}from"./index-297c97b3.js";import{E as xa,__tla as Ma}from"./el-card-22a26825.js";import{M as D,__tla as Va}from"./index-a80b0e55.js";import ka,{__tla as Ca}from"./MerchantTabs-eae0e09d.js";import Sa,{__tla as Da}from"./MerchantApplyTabs-9dfc0e85.js";import{f as Ta,__tla as Ua}from"./formatTime-43b819e0.js";import{g as Ia,__tla as Ha}from"./index-1790b7ea.js";import{c as Na,__tla as Aa}from"./template-ee1dba02.js";import{u as Pa,__tla as Ya}from"./useMessage-8a849e40.js";import{__tla as Ka}from"./index-97931d72.js";import{__tla as za}from"./SPuUploadImg-217bfd78.js";import{__tla as Fa}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-ae102e4a.js";import{__tla as Oa}from"./index-ef616a81.js";import{__tla as ja}from"./el-image-viewer-3c943bf5.js";import{__tla as Ra}from"./Dialog-6d866407.js";import{__tla as Ba}from"./MerchantApplyBaseInfo-8e097b74.js";import{__tla as Ea}from"./Editor-5eae0fc5.js";import{__tla as La}from"./UploadImgs-2eb5bd0c.js";import{__tla as qa}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-22dc46a8.js";import{__tla as Ja}from"./UploadImg-76828272.js";import"./tree-0af4953a.js";let Ye,Qa=Promise.all([(()=>{try{return Qe}catch{}})(),(()=>{try{return Ge}catch{}})(),(()=>{try{return ba}catch{}})(),(()=>{try{return Ma}catch{}})(),(()=>{try{return Va}catch{}})(),(()=>{try{return Ca}catch{}})(),(()=>{try{return Da}catch{}})(),(()=>{try{return Ua}catch{}})(),(()=>{try{return Ha}catch{}})(),(()=>{try{return Aa}catch{}})(),(()=>{try{return Ya}catch{}})(),(()=>{try{return Ka}catch{}})(),(()=>{try{return za}catch{}})(),(()=>{try{return Fa}catch{}})(),(()=>{try{return Oa}catch{}})(),(()=>{try{return ja}catch{}})(),(()=>{try{return Ra}catch{}})(),(()=>{try{return Ba}catch{}})(),(()=>{try{return Ea}catch{}})(),(()=>{try{return La}catch{}})(),(()=>{try{return qa}catch{}})(),(()=>{try{return Ja}catch{}})()]).then(async()=>{let W,Z,$,ee,ae,te,le,ne,oe,se,re,ie,ce,me,de,ue,pe,he,_e,ve,fe,K,ye;W={class:"search"},Z={style:{"text-align":"right"},class:"search-input"},$={class:"searchMore"},ee={style:{display:"flex","justify-content":"space-between","align-items":"center","margin-bottom":"5px"}},ae=["title"],te=["onClick"],le={style:{display:"flex","align-items":"center"}},ne={style:{width:"151px",height:"85px","margin-right":"10px",border:"1px solid rgb(220 223 231)","border-radius":"5px",display:"flex","align-items":"center","justify-content":"center",overflow:"hidden"}},oe=["src"],se={style:{"line-height":"22px",width:"calc(100% - 170px)"}},re=["title"],ie={style:{display:"flex","justify-content":"space-between","align-items":"center","margin-bottom":"5px"}},ce=["title"],me=["onClick"],de={style:{display:"flex","align-items":"center"}},ue={style:{width:"151px",height:"85px","margin-right":"10px",border:"1px solid rgb(220 223 231)","border-radius":"5px",display:"flex","align-items":"center","justify-content":"center",overflow:"hidden"}},pe=["src"],he={style:{"line-height":"30px",width:"calc(100% - 170px)"}},_e=["title"],ve={key:2},fe=[(H=>(ya("data-v-8a189126"),H=H(),ga(),H))(()=>r("p",{style:{"text-align":"center","margin-top":"100px"}},"\u6682\u65E0\u5546\u6237",-1))],K="views/system/sale/merchant/components/MerchantBaseInfo",ye=We({name:"Merchant",__name:"index",setup(H){const{currentRoute:Xa,push:Ke}=Ze(),ze=$e(),T=ea(()=>ze.getMobile),ge=i([{name:"BaseInfo",label:"\u57FA\u672C\u4FE1\u606F",component:"views/system/sale/merchant/components/MerchantBaseInfo"},{name:"Store",label:"\u5E97\u94FA",component:"views/system/sale/merchant/components/MerchantStore"},{name:"Product",label:"\u5546\u54C1",component:"views/system/sale/merchant/components/MerchantProduct"},{name:"Order",label:"\u8BA2\u5355",component:"views/system/sale/merchant/components/MerchantOrder"},{name:"Service",label:"\u5BA2\u670D",component:"views/system/sale/merchant/components/MerchantService"},{name:"AfterSales",label:"\u552E\u540E",component:"views/system/sale/merchant/components/MerchantAfterSales"},{name:"Campaign",label:"\u6D3B\u52A8",component:"views/system/sale/merchant/components/MerchantCampaign"},{name:"Points",label:"\u79EF\u5206",component:"views/system/sale/merchant/components/MerchantPoints"},{name:"Advertisement",label:"\u5E7F\u544A",component:"views/system/sale/merchant/components/MerchantAdvertisement"},{name:"Highlights",label:"\u770B\u70B9",component:"views/system/sale/merchant/components/MerchantHighlights"},{name:"Finance",label:"\u8D22\u52A1",component:"views/system/sale/merchant/components/MerchantFinance"},{name:"Employee",label:"\u4EBA\u5458",component:"views/system/sale/merchant/components/MerchantEmployee"},{name:"ApplyLog",label:"\u5165\u9A7B\u5BA1\u6838\u8BB0\u5F55",component:"views/system/sale/merchant/components/MerchantApplyLog"}]),u=i({id:void 0,name:void 0,status:10,description:void 0,contact:void 0,address:void 0,contactNumber:void 0,website:void 0,complaintsHotline:void 0,createTime:void 0,customerServiceHotline:void 0,email:void 0,businessLicensePicture:void 0,expireTime:void 0,logoUrl:void 0,areaId:void 0,brandLicensing:void 0,otherCertificate:[],legalPerson:void 0,legalPersonNumber:void 0,identityCardFront:void 0,identityCardReverseSide:void 0});aa("updateInitialData",u);const Fe=i([{name:"\u5220\u9664",action:function(){Re(u.value.id)},type:"danger",isAdd:!1},{name:"\u4FDD\u5B58",action:async function(){const n=z.value.ComponentRef.validate();if(!z.value.picUrl)return void U.error("\u8BF7\u4E0A\u4F20logo");const t=await n;if(console.log(t),!!t)try{let d=u.value;d.otherCertificate=d.otherCertificate.map(p=>p.url),u.value.id==null?(await D.createMerchant(d).then(p=>{console.log("\u521B\u5EFA\u6210\u529F",p),console.log(u.value.name),Na({merId:p.merId,shopId:p.shopId,name:u.value.name})}),U.success(B("common.createSuccess")),x()):(await D.updateMerchant(d),U.success(B("common.updateSuccess")),x()),k.value=!1}finally{}},type:"primary",isAdd:!0}]),z=i(),F=i(0),k=i(!1),O=i(""),j=i(!1),we=i("");async function R(n,t){if(we.value=n,t!=null){if(u.value=await D.getMerchant(t.id),T.value)return void Ke({name:"MobileDetail",query:{tabs:JSON.stringify(ge.value),initialComponent:K.value,id:t.id,initialData:JSON.stringify(u.value),opentype:n}});j.value=n=="\u67E5\u770B",O.value=n+"-"+t.name,F.value=t.id}else j.value=!1,O.value=n,F.value=0,function(){for(const d of Object.keys(u.value))u.value[d]=void 0;u.value.status=10}();k.value=!0}const be=i();async function xe(n,t){be.value.open(n,t)}const N=i(!1);function Me(n){b.value[n].showSetting=!0}function Ve(n){b.value[n].showSetting=!1}const Oe=()=>{N.value=!N.value},ke=()=>{N.value=!1},U=Pa(),{t:B}=ta(),A=i(!0),b=i([]),E=i(0),s=la({pageNo:1,pageSize:10,name:void 0,status:void 0,description:void 0,contact:void 0,address:void 0,contactNumber:void 0,website:void 0,complaintsHotline:void 0,customerServiceHotline:void 0,email:void 0,expireTime:[],createTime:[]}),Ce=i();i(!1);const x=async()=>{A.value=!0;try{const n=await D.getMerchantPage(s);n.list.forEach(t=>{t.showSetting=!1}),b.value=n.list,E.value=n.total}finally{A.value=!1}},L=async()=>{A.value=!0;try{const n=await D.getMerchantApplyPage({checkStatus:0});n.list.forEach(t=>{t.showSetting=!1}),b.value=n.list,E.value=n.total}finally{A.value=!1}},f=()=>{s.pageNo=1,x(),ke()},je=()=>{Ce.value.resetFields(),f()};i();const Re=async n=>{try{await U.delConfirm(),await D.deleteMerchant(n),U.success(B("common.delSuccess")),await x(),k.value=!1}catch{}},Se=i([]),De=n=>((d,p)=>{const h=[];let c=p;for(;c!==null;){const m=d.get(c);if(!m)break;h.unshift(m.name),c=m.parentId}return h})((d=>{const p=new Map,h=[...d.map(c=>({...c,parentId:null}))];for(;h.length>0;){const c=h.pop();p.set(c.id,{name:c.name,parentId:c.parentId}),c.children&&h.push(...c.children.map(m=>({...m,parentId:c.id})))}return p})(Se.value),n).join("/"),g=i(0),Be=n=>{g.value=n.paneName,g.value==0?L():x()};return na(async()=>{Se.value=await Ia(),g.value==0?L():x()}),(n,t)=>{const d=ra,p=ia,h=ca,c=ma,m=da,v=ua,Te=pa,q=ha,J=_a,Ee=va,Ue=fa,Ie=xa,Le=Xe,qe=Je,Q=oa("hasPermi");return _(),C(G,null,[l(qe,{class:"Content",style:{"min-height":"400px",border:"unset"}},{default:o(()=>[r("div",W,[a(T)?I("",!0):(_(),S(p,{key:0,modelValue:a(g),"onUpdate:modelValue":t[0]||(t[0]=e=>He(g)?g.value=e:null),onTabClick:Be,class:"parent-tabs"},{default:o(()=>[l(d,{label:"\u5F85\u5BA1\u6838",name:0}),l(d,{label:"\u5728\u7528",name:1})]),_:1},8,["modelValue"])),r("div",Z,[l(h,{icon:a(sa),onClick:Oe},null,8,["icon"]),a(T)?I("",!0):P((_(),S(h,{key:0,onClick:t[1]||(t[1]=e=>R("\u65B0\u589E"))},{default:o(()=>[l(c,{class:"mr-5px",icon:"ep:plus"}),Y(" \u65B0\u589E ")]),_:1})),[[Q,["sale:merchant:create"]]])])]),P(r("div",$,[l(Ee,{class:"-mb-15px",model:a(s),ref_key:"queryFormRef",ref:Ce,inline:!0,"label-width":"68px"},{default:o(()=>[l(v,{label:"\u5546\u6237\u540D\u79F0",prop:"name"},{default:o(()=>[l(m,{modelValue:a(s).name,"onUpdate:modelValue":t[2]||(t[2]=e=>a(s).name=e),placeholder:"\u8BF7\u8F93\u5165\u5546\u6237\u540D\u79F0",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u8D1F\u8D23\u4EBA",prop:"contact"},{default:o(()=>[l(m,{modelValue:a(s).contact,"onUpdate:modelValue":t[3]||(t[3]=e=>a(s).contact=e),placeholder:"\u8BF7\u8F93\u5165\u8D1F\u8D23\u4EBA",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u6240\u5728\u5730",prop:"address"},{default:o(()=>[l(m,{modelValue:a(s).address,"onUpdate:modelValue":t[4]||(t[4]=e=>a(s).address=e),placeholder:"\u8BF7\u8F93\u5165\u6240\u5728\u5730",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u8D1F\u8D23\u4EBA\u7535\u8BDD",prop:"contactNumber"},{default:o(()=>[l(m,{modelValue:a(s).contactNumber,"onUpdate:modelValue":t[5]||(t[5]=e=>a(s).contactNumber=e),placeholder:"\u8BF7\u8F93\u5165\u8D1F\u8D23\u4EBA\u7535\u8BDD",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u5B98\u7F51",prop:"website"},{default:o(()=>[l(m,{modelValue:a(s).website,"onUpdate:modelValue":t[6]||(t[6]=e=>a(s).website=e),placeholder:"\u8BF7\u8F93\u5165\u5B98\u7F51",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u7EF4\u6743\u7535\u8BDD",prop:"complaintsHotline"},{default:o(()=>[l(m,{modelValue:a(s).complaintsHotline,"onUpdate:modelValue":t[7]||(t[7]=e=>a(s).complaintsHotline=e),placeholder:"\u8BF7\u8F93\u5165\u7EF4\u6743\u7535\u8BDD",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u5BA2\u670D\u7535\u8BDD",prop:"customerServiceHotline"},{default:o(()=>[l(m,{modelValue:a(s).customerServiceHotline,"onUpdate:modelValue":t[8]||(t[8]=e=>a(s).customerServiceHotline=e),placeholder:"\u8BF7\u8F93\u5165\u5BA2\u670D\u7535\u8BDD",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u90AE\u7BB1",prop:"email"},{default:o(()=>[l(m,{modelValue:a(s).email,"onUpdate:modelValue":t[9]||(t[9]=e=>a(s).email=e),placeholder:"\u8BF7\u8F93\u5165\u90AE\u7BB1",clearable:"",onKeyup:w(f,["enter"])},null,8,["modelValue"])]),_:1}),l(v,{label:"\u670D\u52A1\u5230\u671F\u65F6\u95F4",prop:"expireTime"},{default:o(()=>[l(Te,{modelValue:a(s).expireTime,"onUpdate:modelValue":t[10]||(t[10]=e=>a(s).expireTime=e),style:{width:"auto"},"value-format":"YYYY-MM-DD HH:mm:ss",type:"daterange","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")]},null,8,["modelValue","default-time"])]),_:1}),l(v,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:o(()=>[l(Te,{modelValue:a(s).createTime,"onUpdate:modelValue":t[11]||(t[11]=e=>a(s).createTime=e),style:{width:"auto"},"value-format":"YYYY-MM-DD HH:mm:ss",type:"daterange","start-placeholder":"\u5F00\u59CB\u65E5\u671F","end-placeholder":"\u7ED3\u675F\u65E5\u671F","default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")]},null,8,["modelValue","default-time"])]),_:1}),l(J,null,{default:o(()=>[l(q,null,{default:o(()=>[l(v,null,{default:o(()=>[l(h,{onClick:ke},{default:o(()=>[Y(" \u6536\u8D77 ")]),_:1}),l(h,{onClick:je},{default:o(()=>[Y(" \u91CD\u7F6E ")]),_:1}),l(h,{onClick:f},{default:o(()=>[l(c,{icon:"ep:search",class:"mr-5px"}),Y(" \u641C\u7D22 ")]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])],512),[[X,a(N)]]),a(g)===0?(_(),S(J,{key:0},{default:o(()=>[(_(!0),C(G,null,Ne(a(b),(e,M)=>(_(),S(q,{class:"card",key:M,span:7,xl:7,lg:7,md:7,sm:24,xs:24,onMouseover:V=>Me(M),onMouseout:V=>Ve(M)},{default:o(()=>[l(Ie,{onClick:V=>xe("\u67E5\u770B",e)},{default:o(()=>[r("div",ee,[r("p",{style:{width:"100%","white-space":"nowrap","text-overflow":"ellipsis",overflow:"hidden","font-size":"16px",color:"#000"},title:e.name},y(e.name),9,ae),P((_(),C("div",{onClick:Ae(V=>xe("\u7F16\u8F91",e),["stop"]),class:"setting"},[l(Ue,{size:"20",color:"rgb(220 223 231)"},{default:o(()=>[l(a(Pe))]),_:1})],8,te)),[[X,e.showSetting&&!a(T)],[Q,["sale:merchant:update"]]])]),r("div",le,[r("div",ne,[r("img",{src:e.logoUrl,style:{width:"auto",height:"auto","max-width":"100%","max-height":"100%"}},null,8,oe)]),r("div",se,[r("p",null,"\u8054\u7EDC\u4EBA:"+y(e.contact),1),r("p",null,"\u8054\u7EDC\u4EBA\u624B\u673A\u53F7:"+y(e.contactNumber),1),r("p",null,"\u7533\u8BF7\u65F6\u95F4:"+y(a(Ta)(e.createTime,"YYYY-MM-DD")),1),r("p",{style:{"white-space":"nowrap","text-overflow":"ellipsis",width:"100%",overflow:"hidden"},title:e.address},y(De(e.areaId)),9,re)])])]),_:2},1032,["onClick"])]),_:2},1032,["onMouseover","onMouseout"]))),128))]),_:1})):I("",!0),a(g)===1?(_(),S(J,{key:1},{default:o(()=>[(_(!0),C(G,null,Ne(a(b),(e,M)=>(_(),S(q,{class:"card",key:M,span:7,xl:7,lg:7,md:7,sm:24,xs:24,onMouseover:V=>Me(M),onMouseout:V=>Ve(M)},{default:o(()=>[l(Ie,{onClick:V=>R("\u67E5\u770B",e)},{default:o(()=>[r("div",ie,[r("p",{style:{width:"100%","white-space":"nowrap","text-overflow":"ellipsis",overflow:"hidden","font-size":"16px",color:"#000"},title:e.name},y(e.name),9,ce),P((_(),C("div",{onClick:Ae(V=>R("\u7F16\u8F91",e),["stop"]),class:"setting"},[l(Ue,{size:"20",color:"rgb(220 223 231)"},{default:o(()=>[l(a(Pe))]),_:1})],8,me)),[[X,e.showSetting&&!a(T)],[Q,["sale:merchant:update"]]])]),r("div",de,[r("div",ue,[r("img",{src:e.logoUrl,style:{width:"auto",height:"auto","max-width":"100%","max-height":"100%"}},null,8,pe)]),r("div",he,[r("p",null,"\u9500\u91CF:"+y(e.salesVolume),1),r("p",null,"\u5546\u54C1\u6570\u91CF:"+y(e.skuCount),1),r("p",{style:{"white-space":"nowrap","text-overflow":"ellipsis",width:"100%",overflow:"hidden"},title:e.address},y(De(e.areaId)),9,_e)])])]),_:2},1032,["onClick"])]),_:2},1032,["onMouseover","onMouseout"]))),128))]),_:1})):I("",!0),a(b).length===0?(_(),C("div",ve,[...fe])):I("",!0),l(Le,{total:a(E),page:a(s).pageNo,"onUpdate:page":t[12]||(t[12]=e=>a(s).pageNo=e),limit:a(s).pageSize,"onUpdate:limit":t[13]||(t[13]=e=>a(s).pageSize=e),onPagination:x},null,8,["total","page","limit"])]),_:1}),l(ka,{tabs:a(ge),initialData:a(u),buttonActions:a(Fe),ref_key:"MerchantTabsRef",ref:z,isDetail:a(j),initialComponent:K,dialogTitle:a(O),id:a(F),modelValue:a(k),"onUpdate:modelValue":t[14]||(t[14]=e=>He(k)?k.value=e:null),openType:a(we)},null,8,["tabs","initialData","buttonActions","isDetail","dialogTitle","id","modelValue","openType"]),l(Sa,{ref_key:"MerchantApplyTabsRef",ref:be,onSuccess:L},null,512)],64)}}}),Ye=wa(ye,[["__scopeId","data-v-8a189126"],["__file","D:/zx/mall-newfeifan-zx-admin/src/views/system/sale/merchant/index.vue"]])});export{Qa as __tla,Ye as default};
|