index-2e0b64fb.js 7.4 KB

1
  1. import{d as Z,P as j,r as n,x as B,b as G,a4 as $,o as i,c as k,f as a,A as l,a as e,a5 as z,F as C,R as O,C as c,D as u,k as w,E as aa,S as ta,U as ea,V as la,a9 as ra,I as oa,Q as _a,J as ia,W as na,X as sa,Y as ca,Z as ua,_ as pa,__tla as ma}from"./index-f6fb8e95.js";import{_ as da,__tla as fa}from"./index-58a94653.js";import{_ as ya,__tla as ha}from"./DictTag-81730a57.js";import{E as wa,__tla as ga}from"./el-image-fefb4b54.js";import{__tla as ba}from"./el-image-viewer-cfdb08a7.js";import{_ as va,__tla as xa}from"./ContentWrap-96bb70ec.js";import{a as ka,D as Y,__tla as Ca}from"./dict-c9a7f6a4.js";import{d as Va,__tla as Ua}from"./formatTime-ddd96ac8.js";import{a as Sa,d as Ta,__tla as Ia}from"./index-eef9c382.js";import Da,{__tla as Ma}from"./ArticleForm-7d393e38.js";import{g as Na,__tla as Pa}from"./index-94688cab.js";import{i as za,__tla as Oa}from"./spu-a7f31871.js";import{c as Ya,__tla as Aa}from"./index-b76b57e5.js";import{u as Ra,__tla as Ea}from"./useMessage-3b767a67.js";import{__tla as Fa}from"./index-07a2f7ed.js";import"./color-6e929987.js";import{__tla as qa}from"./el-card-8db16709.js";import{__tla as Ha}from"./Dialog-ac2b0e4e.js";import{__tla as Ka}from"./Editor-87b5f27a.js";import{__tla as Ja}from"./UploadImg-76a51b31.js";import{__tla as La}from"./SpuSelect-90cd6073.js";import{__tla as Qa}from"./el-tree-select-25b2ed74.js";import{__tla as Wa}from"./index-8bf65b8f.js";import{__tla as Xa}from"./SkuList-d402df2e.js";import{__tla as Za}from"./SPuUploadImg.vue_vue_type_style_index_0_scoped_ba706063_lang-8b438c45.js";import{__tla as ja}from"./UploadImgs.vue_vue_type_style_index_0_scoped_9d666400_lang-1b59ad7e.js";import{__tla as Ba}from"./UploadFile.vue_vue_type_style_index_0_scoped_436eca1b_lang-3d49d983.js";import"./tree-0af4953a.js";import{__tla as Ga}from"./category-4baa8823.js";let A,$a=Promise.all([(()=>{try{return ma}catch{}})(),(()=>{try{return fa}catch{}})(),(()=>{try{return ha}catch{}})(),(()=>{try{return ga}catch{}})(),(()=>{try{return ba}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return Ca}catch{}})(),(()=>{try{return Ua}catch{}})(),(()=>{try{return Ia}catch{}})(),(()=>{try{return Ma}catch{}})(),(()=>{try{return Pa}catch{}})(),(()=>{try{return Oa}catch{}})(),(()=>{try{return Aa}catch{}})(),(()=>{try{return Ea}catch{}})(),(()=>{try{return Fa}catch{}})(),(()=>{try{return qa}catch{}})(),(()=>{try{return Ha}catch{}})(),(()=>{try{return Ka}catch{}})(),(()=>{try{return Ja}catch{}})(),(()=>{try{return La}catch{}})(),(()=>{try{return Qa}catch{}})(),(()=>{try{return Wa}catch{}})(),(()=>{try{return Xa}catch{}})(),(()=>{try{return Za}catch{}})(),(()=>{try{return ja}catch{}})(),(()=>{try{return Ba}catch{}})(),(()=>{try{return Ga}catch{}})()]).then(async()=>{A=pa(Z({name:"PromotionArticle",__name:"index",setup(at){const V=Ra(),{t:R}=j(),g=n(!0),U=n(0),S=n([]),o=B({pageNo:1,pageSize:10,categoryId:void 0,title:null,status:void 0,spuId:void 0,createTime:[]}),T=n(),p=async()=>{g.value=!0;try{const m=await Sa(o);S.value=m.list,U.value=m.total}finally{g.value=!1}},h=()=>{o.pageNo=1,p()},E=()=>{T.value.resetFields(),h()},I=n(),D=(m,r)=>{I.value.open(m,r)},b=n([]),F=n([]);return G(async()=>{await p(),b.value=await Na(),F.value=await za()}),(m,r)=>{const M=ta,N=ea,d=la,q=ra,H=oa,v=_a,f=ia,K=na,P=va,J=wa,_=sa,L=ya,Q=ca,W=da,x=$("hasPermi"),X=ua;return i(),k(C,null,[a(P,null,{default:l(()=>[a(K,{ref_key:"queryFormRef",ref:T,inline:!0,model:e(o),class:"-mb-15px","label-width":"80px"},{default:l(()=>[a(d,{label:"\u6587\u7AE0\u5206\u7C7B",prop:"categoryId"},{default:l(()=>[a(N,{modelValue:e(o).categoryId,"onUpdate:modelValue":r[0]||(r[0]=t=>e(o).categoryId=t),class:"!w-240px",placeholder:"\u5168\u90E8",onKeyup:z(h,["enter"])},{default:l(()=>[(i(!0),k(C,null,O(e(b),t=>(i(),c(M,{key:t.id,label:t.name,value:t.id},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(d,{label:"\u6587\u7AE0\u6807\u9898",prop:"title"},{default:l(()=>[a(q,{modelValue:e(o).title,"onUpdate:modelValue":r[1]||(r[1]=t=>e(o).title=t),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u8F93\u5165\u6587\u7AE0\u6807\u9898",onKeyup:z(h,["enter"])},null,8,["modelValue"])]),_:1}),a(d,{label:"\u72B6\u6001",prop:"status"},{default:l(()=>[a(N,{modelValue:e(o).status,"onUpdate:modelValue":r[2]||(r[2]=t=>e(o).status=t),class:"!w-240px",clearable:"",placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001"},{default:l(()=>[(i(!0),k(C,null,O(e(ka)(e(Y).COMMON_STATUS),t=>(i(),c(M,{key:t.value,label:t.label,value:t.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(d,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:l(()=>[a(H,{modelValue:e(o).createTime,"onUpdate:modelValue":r[3]||(r[3]=t=>e(o).createTime=t),"default-time":[new Date("1 00:00:00"),new Date("1 23:59:59")],class:"!w-240px","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}),a(d,null,{default:l(()=>[a(f,{onClick:h},{default:l(()=>[a(v,{class:"mr-5px",icon:"ep:search"}),u(" \u641C\u7D22 ")]),_:1}),a(f,{onClick:E},{default:l(()=>[a(v,{class:"mr-5px",icon:"ep:refresh"}),u(" \u91CD\u7F6E ")]),_:1}),w((i(),c(f,{plain:"",type:"primary",onClick:r[4]||(r[4]=t=>D("create"))},{default:l(()=>[a(v,{class:"mr-5px",icon:"ep:plus"}),u(" \u65B0\u589E ")]),_:1})),[[x,["promotion:article:create"]]])]),_:1})]),_:1},8,["model"])]),_:1}),a(P,null,{default:l(()=>[w((i(),c(Q,{data:e(S),"show-overflow-tooltip":!0,stripe:!0},{default:l(()=>[a(_,{align:"center",label:"\u5C01\u9762","min-width":"80",prop:"picUrl"},{default:l(({row:t})=>[a(J,{src:t.picUrl,class:"h-30px w-30px",onClick:y=>{return s=t.picUrl,void Ya({urlList:[s]});var s}},null,8,["src","onClick"])]),_:1}),a(_,{align:"center",label:"\u6807\u9898","min-width":"180",prop:"title"}),a(_,{align:"center",label:"\u5206\u7C7B","min-width":"180",prop:"categoryId"},{default:l(t=>{var y;return[u(aa((y=e(b).find(s=>s.id===t.row.categoryId))==null?void 0:y.name),1)]}),_:1}),a(_,{align:"center",label:"\u6D4F\u89C8\u91CF","min-width":"180",prop:"browseCount"}),a(_,{align:"center",label:"\u4F5C\u8005","min-width":"180",prop:"author"}),a(_,{align:"center",label:"\u6587\u7AE0\u7B80\u4ECB","min-width":"250",prop:"introduction"}),a(_,{align:"center",label:"\u6392\u5E8F","min-width":"60",prop:"sort"}),a(_,{align:"center",label:"\u72B6\u6001","min-width":"60",prop:"status"},{default:l(t=>[a(L,{type:e(Y).COMMON_STATUS,value:t.row.status},null,8,["type","value"])]),_:1}),a(_,{formatter:e(Va),align:"center",label:"\u53D1\u5E03\u65F6\u95F4",prop:"createTime",width:"180px"},null,8,["formatter"]),a(_,{align:"center",fixed:"right",label:"\u64CD\u4F5C",width:"120"},{default:l(t=>[w((i(),c(f,{link:"",type:"primary",onClick:y=>D("update",t.row.id)},{default:l(()=>[u(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[x,["promotion:article:update"]]]),w((i(),c(f,{link:"",type:"danger",onClick:y=>(async s=>{try{await V.delConfirm(),await Ta(s),V.success(R("common.delSuccess")),await p()}catch{}})(t.row.id)},{default:l(()=>[u(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[x,["promotion:article:delete"]]])]),_:1})]),_:1},8,["data"])),[[X,e(g)]]),a(W,{limit:e(o).pageSize,"onUpdate:limit":r[5]||(r[5]=t=>e(o).pageSize=t),page:e(o).pageNo,"onUpdate:page":r[6]||(r[6]=t=>e(o).pageNo=t),total:e(U),onPagination:p},null,8,["limit","page","total"])]),_:1}),a(Da,{ref_key:"formRef",ref:I,onSuccess:p},null,512)],64)}}}),[["__file","D:/zx/mall-newfeifan-zx-admin/src/views/mall/promotion/article/index.vue"]])});export{$a as __tla,A as default};