index-a2547475.js 11 KB

1
  1. import{_ as ga,__tla as ba}from"./ContentWrap-1470ffc8.js";import{_ as wa,__tla as xa}from"./index-92d2fe50.js";import{d as Ia,Y as ka,K as Va,h as Ta,u as Ca,r as u,aI as Sa,l as Ma,o as s,v as p,w as o,c as y,a as t,F as k,q as V,P as T,g as n,f as r,R as Pa,e7 as Ua,dD as Da,x as za,n as M,a4 as Na,t as f,at as ja,W as Ya,X as Ea,aM as qa,C as Ha,V as Ra,y as Ba,z as Fa,A as Ka,aS as La,B as Aa,j as Ga,E as Ja,i as Qa,D as Wa,p as Xa,k as Za,_ as $a,__tla as Oa}from"./index-c6f9ee0e.js";import{E as at,__tla as tt}from"./el-card-b8cdac7a.js";import{__tla as et}from"./index-7a4d19dc.js";import{h as lt,d as rt}from"./tree-0af4953a.js";import{d as ot}from"./constants-a3c69b57.js";import{e as _t,d as st,f as nt,b as ut,__tla as ct}from"./spu-04b8dd7c.js";import{h as it,__tla as mt}from"./index-218f8164.js";import{g as pt,__tla as dt}from"./category-cf87caae.js";import yt,{__tla as ft}from"./index-7061f72c.js";import{u as ht,__tla as vt}from"./useMessage-04fcbc39.js";import{__tla as gt}from"./ContentWrap.vue_vue_type_script_setup_true_lang-e83f65ab.js";import{__tla as bt}from"./index-75e9b2f8.js";import{__tla as wt}from"./el-image-viewer-7498b9bf.js";import{__tla as xt}from"./SPuUploadImg-1669f9d2.js";import{__tla as It}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-e8b91668.js";import{__tla as kt}from"./tagsView-5ae206df.js";import{__tla as Vt}from"./InfoForm-7f37ae95.js";import{__tla as Tt}from"./UploadImgs-8b13c573.js";import{__tla as Ct}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-a923fb3d.js";import{__tla as St}from"./brand-76fb0cb5.js";import{__tla as Mt}from"./formRules-89328b2c.js";import{__tla as Pt}from"./DescriptionForm-b62a22d4.js";import{__tla as Ut}from"./Editor-27247565.js";import{__tla as Dt}from"./OtherForm-56366547.js";import{__tla as zt}from"./SkuForm-619422df.js";import{__tla as Nt}from"./index-e4ddfbc4.js";import{__tla as jt}from"./SkuList-52f13e2b.js";import{__tla as Yt}from"./el-image-6b7893db.js";import{__tla as Et}from"./UploadImg-c59f0149.js";import{__tla as qt}from"./UploadFile.vue_vue_type_style_index_0_scoped_436eca1b_lang-3780f935.js";import{__tla as Ht}from"./ProductAttributes-7ea96c68.js";import{__tla as Rt}from"./el-text-b62f487c.js";import{__tla as Bt}from"./property-d18a8a70.js";import{__tla as Ft}from"./ProductPropertyAddForm-907afba4.js";import{__tla as Kt}from"./Dialog-a9930e5b.js";import{__tla as Lt}from"./DeliveryForm-9615fc83.js";import{__tla as At}from"./index-0170f9a5.js";import{__tla as Gt}from"./dict-44cf9190.js";import{__tla as Jt}from"./Service-db4aa88d.js";import{__tla as Qt}from"./index-8a0250a8.js";import{__tla as Wt}from"./AfterSale-4c8c4087.js";import{__tla as Xt}from"./Comment-80114168.js";let O,Zt=Promise.all([(()=>{try{return ba}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return Oa}catch{}})(),(()=>{try{return tt}catch{}})(),(()=>{try{return et}catch{}})(),(()=>{try{return ct}catch{}})(),(()=>{try{return mt}catch{}})(),(()=>{try{return dt}catch{}})(),(()=>{try{return ft}catch{}})(),(()=>{try{return vt}catch{}})(),(()=>{try{return gt}catch{}})(),(()=>{try{return bt}catch{}})(),(()=>{try{return wt}catch{}})(),(()=>{try{return xt}catch{}})(),(()=>{try{return It}catch{}})(),(()=>{try{return kt}catch{}})(),(()=>{try{return Vt}catch{}})(),(()=>{try{return Tt}catch{}})(),(()=>{try{return Ct}catch{}})(),(()=>{try{return St}catch{}})(),(()=>{try{return Mt}catch{}})(),(()=>{try{return Pt}catch{}})(),(()=>{try{return Ut}catch{}})(),(()=>{try{return Dt}catch{}})(),(()=>{try{return zt}catch{}})(),(()=>{try{return Nt}catch{}})(),(()=>{try{return jt}catch{}})(),(()=>{try{return Yt}catch{}})(),(()=>{try{return Et}catch{}})(),(()=>{try{return qt}catch{}})(),(()=>{try{return Ht}catch{}})(),(()=>{try{return Rt}catch{}})(),(()=>{try{return Bt}catch{}})(),(()=>{try{return Ft}catch{}})(),(()=>{try{return Kt}catch{}})(),(()=>{try{return Lt}catch{}})(),(()=>{try{return At}catch{}})(),(()=>{try{return Gt}catch{}})(),(()=>{try{return Jt}catch{}})(),(()=>{try{return Qt}catch{}})(),(()=>{try{return Wt}catch{}})(),(()=>{try{return Xt}catch{}})()]).then(async()=>{let P,U,D,z,N,j,Y,E,q,H,R;P={key:0,class:"search"},U={style:{"text-align":"right"},class:"search-input"},D={class:"searchMore"},z={style:{display:"flex","justify-content":"space-between","align-items":"center","margin-bottom":"5px"}},N=["title"],j={style:{display:"flex","align-items":"center"}},Y={style:{width:"178px",height:"100px","margin-right":"10px",border:"1px solid rgb(220 223 231)","border-radius":"5px",display:"flex","align-items":"center","justify-content":"center",overflow:"hidden"}},E=["src"],q={style:{"line-height":"25px"}},H={key:1},R=[(c=>(Xa("data-v-b78c7ed6"),c=c(),Za(),c))(()=>n("p",{style:{"text-align":"center","margin-top":"100px"}},"\u6682\u65E0\u5546\u54C1",-1))],O=$a(Ia({name:"ProductSpu",__name:"index",props:{merchantId:{type:Number,default:void 0},userId:{type:Number,default:void 0},isDetail:{type:Boolean,default:!1}},setup(c){const aa=ka(),B=Va(()=>aa.getMobile),i=c;ht(),Ta();const{push:ta}=Ca(),C=u(!1);u(!1);const F=u(0),h=u([]),v=u([{name:"\u5168\u90E8",type:"",count:0},{name:"\u51FA\u552E\u4E2D",type:0,count:0},{name:"\u4ED3\u5E93\u4E2D",type:1,count:0},{name:"\u5DF2\u552E\u7F44",type:2,count:0},{name:"\u8B66\u6212\u5E93\u5B58",type:3,count:0},{name:"\u56DE\u6536\u7AD9",type:4,count:0}]),e=u({pageNo:1,pageSize:10,tabType:"",name:"",categoryId:void 0,createTime:void 0,shopId:void 0}),ea=u(),g=u(!1),la=()=>{g.value=!g.value},ra=()=>{g.value=!1},d=async()=>{C.value=!0,i.merchantId&&(e.value.merchantId=i.merchantId);try{let _;i.userId?(console.log(i.userId),e.value.userId=i.userId,_=await _t(e.value)):_=await st(e.value),_.list.forEach(l=>{l.showSetting=!1}),h.value=_.list,F.value=_.total}finally{C.value=!1,g.value=!1,K()}},oa=_=>{e.value.tabType=_.paneName,d()},K=async()=>{const _=u({...e.value});let l;i.merchantId?(_.value.merId=i.merchantId,l=await nt(_.value)):l=await ut(_.value),v.value[0].count=0;for(let m in l)(m<=1||m==="4")&&(v.value[0].count+=l[m]),v.value[Number(m)+1].count=l[m]},x=()=>{d()},_a=()=>{e.value.categoryId=void 0,e.value.createTime=void 0,e.value.name="",e.value.tabType="",e.value.shopId=void 0,x()},L=u(),A=u();Sa(()=>{d()});let G=u([]);return Ma(async()=>{await(async()=>{C.value=!0;const l=await it();G.value=l})(),await K(),await d();const _=await pt({});A.value=lt(_,"id","parentId")}),(_,l)=>{const m=Ya,sa=Ea,na=qa,I=Ha,ua=Ra,J=Ba,Q=Fa,b=Ka,ca=La,ia=Aa,ma=Ga,W=Ja,X=Qa,pa=Wa,da=at,ya=wa,fa=ga;return s(),p(fa,{style:{},class:"container"},{default:o(()=>[c.userId?T("",!0):(s(),y("div",P,[t(B)?T("",!0):(s(),p(sa,{key:0,modelValue:t(e).tabType,"onUpdate:modelValue":l[0]||(l[0]=a=>t(e).tabType=a),onTabClick:oa,class:"parent-tabs"},{default:o(()=>[(s(!0),y(k,null,V(t(v),a=>(s(),p(m,{key:a.type,label:a.name+"("+a.count+")",name:a.type},null,8,["label","name"]))),128))]),_:1},8,["modelValue"])),n("div",U,[r(ua,{modelValue:t(e).name,"onUpdate:modelValue":l[1]||(l[1]=a=>t(e).name=a),placeholder:"\u5546\u54C1\u540D\u79F0",onKeyup:Pa(x,["enter"]),class:"!w-240px"},{suffix:o(()=>[r(na,{class:"el-input__icon",onClick:x,style:{cursor:"pointer"}},{default:o(()=>[r(t(Ua))]),_:1})]),append:o(()=>[r(I,{icon:t(Da),onClick:la},null,8,["icon"])]),_:1},8,["modelValue"])])])),za(n("div",D,[r(pa,{ref_key:"queryFormRef",ref:ea,inline:!0,model:t(e),class:"-mb-15px","label-width":"68px"},{default:o(()=>[c.merchantId||c.userId?T("",!0):(s(),p(b,{key:0,label:"\u5E97\u94FA\u540D\u79F0"},{default:o(()=>[r(Q,{modelValue:t(e).shopId,"onUpdate:modelValue":l[2]||(l[2]=a=>t(e).shopId=a),placeholder:"\u8BF7\u9009\u62E9",filterable:""},{default:o(()=>[(s(!0),y(k,null,V(t(G),a=>(s(),p(J,{key:a.id,label:a.name,value:a.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1})),r(b,{label:"\u5546\u54C1\u5206\u7C7B",prop:"categoryId"},{default:o(()=>[r(ca,{modelValue:t(e).categoryId,"onUpdate:modelValue":l[3]||(l[3]=a=>t(e).categoryId=a),options:t(A),props:t(rt),clearable:"",filterable:"",placeholder:"\u8BF7\u9009\u62E9\u5546\u54C1\u5206\u7C7B"},null,8,["modelValue","options","props"])]),_:1}),r(b,{label:"\u5546\u54C1\u72B6\u6001",prop:""},{default:o(()=>[r(Q,{modelValue:t(e).tabType,"onUpdate:modelValue":l[4]||(l[4]=a=>t(e).tabType=a),placeholder:"\u5168\u90E8"},{default:o(()=>[(s(!0),y(k,null,V(t(v),a=>(s(),p(J,{key:a.type,label:a.name,value:a.type},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),r(b,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:o(()=>[r(ia,{style:{"margin-right":"unset",width:"auto !important"},modelValue:t(e).createTime,"onUpdate:modelValue":l[5]||(l[5]=a=>t(e).createTime=a),"default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")],"end-placeholder":"\u7ED3\u675F\u65E5\u671F","start-placeholder":"\u5F00\u59CB\u65E5\u671F",type:"daterange","value-format":"YYYY-MM-DD HH:mm:ss"},null,8,["modelValue","default-time"])]),_:1}),r(X,null,{default:o(()=>[r(W,null,{default:o(()=>[r(b,null,{default:o(()=>[r(I,{onClick:ra},{default:o(()=>[M(" \u6536\u8D77 ")]),_:1}),r(I,{onClick:_a},{default:o(()=>[M(" \u91CD\u7F6E ")]),_:1}),r(I,{onClick:x,plain:"",type:"primary"},{default:o(()=>[r(ma,{class:"mr-5px",icon:"ep:search"}),M(" \u641C\u7D22 ")]),_:1})]),_:1})]),_:1})]),_:1})]),_:1},8,["model"])],512),[[Na,t(g)]]),r(X,null,{default:o(()=>[(s(!0),y(k,null,V(t(h),(a,S)=>(s(),p(W,{class:"card",key:S,span:7,xl:7,lg:7,md:7,sm:24,xs:24,onMouseover:Z=>function(w){h.value[w].showSetting=!0}(S),onMouseout:Z=>function(w){h.value[w].showSetting=!1}(S)},{default:o(()=>[r(da,{onClick:Z=>((w,$,ha)=>{const va=$.id;B.value?ta({name:"ProductSpuMobileDetail",params:{id:va}}):L.value.open(w,$,ha)})("view",a,t(ot).RECYCLE.status,t(e).tabType)},{default:o(()=>[n("div",z,[n("p",{style:{width:"100%","white-space":"nowrap","text-overflow":"ellipsis",overflow:"hidden","font-size":"16px",color:"#000"},title:a.name},f(a.name),9,N)]),n("div",j,[n("div",Y,[n("img",{src:a.picUrl,style:{width:"100%",height:"100%","object-fit":"cover","object-position":"center"}},null,8,E)]),n("div",q,[n("p",null,f(a.spuPayType==2?"\u79EF\u5206:":"\xA5")+" "+f(a.highPrecision?(a.highPrecisionPrice/100).toFixed(6):t(ja)(a.price)),1),n("p",null,"\u9500\u91CF:"+f(a.salesCount),1),n("p",null,"\u5E93\u5B58:"+f(a.stock),1),n("p",null,"\u72B6\u6001:"+f(a.status==1?"\u4E0A\u67B6":"\u4E0B\u67B6"),1)])])]),_:2},1032,["onClick"])]),_:2},1032,["onMouseover","onMouseout"]))),128))]),_:1}),t(h).length==0?(s(),y("div",H,[...R])):T("",!0),r(ya,{limit:t(e).pageSize,"onUpdate:limit":l[6]||(l[6]=a=>t(e).pageSize=a),page:t(e).pageNo,"onUpdate:page":l[7]||(l[7]=a=>t(e).pageNo=a),total:t(F),onPagination:d},null,8,["limit","page","total"]),r(yt,{ref_key:"formRef",ref:L,onSuccess:d},null,512)]),_:1})}}}),[["__scopeId","data-v-b78c7ed6"],["__file","D:/zx/mall-newfeifan-zx-admin/src/views/mall/product/spu/index.vue"]])});export{Zt as __tla,O as default};