index-58bcb26d.js 5.4 KB

1
  1. import{d as I,B as J,r as p,f as L,z as X,S as E,o,c as w,i as a,w as l,a as t,T as Q,F as M,C as W,j as m,m as i,D as f,l as Z,X as $,I as aa,G as ea,H as ta,p as la,_ as ra,q as sa,J as oa,K as _a,L as na,M as ua,__tla as ca}from"./index-1e808f2e.js";import{_ as pa,__tla as ma}from"./index.vue_vue_type_script_setup_true_lang-571824c6.js";import{_ as ia,__tla as da}from"./DictTag.vue_vue_type_script_lang-5c02ebfe.js";import{_ as fa,__tla as ya}from"./ContentWrap.vue_vue_type_script_setup_true_lang-cc335a20.js";import{a as ha,D,__tla as ba}from"./dict-a31cb4ba.js";import{d as ga,__tla as wa}from"./formatTime-a348c3be.js";import{b as va,d as ka,__tla as xa}from"./brand-b7ab0146.js";import{_ as Ca,__tla as Sa}from"./BrandForm.vue_vue_type_script_setup_true_lang-7a02a2b1.js";import{u as Ta,__tla as Ua}from"./useMessage-5f9e8917.js";import{__tla as Va}from"./index-73afebcf.js";import"./color-6e929987.js";import{__tla as Ma}from"./el-card-03b3588b.js";import{__tla as Da}from"./Dialog-f44f9d78.js";import"./_plugin-vue_export-helper-1b428a4d.js";import{__tla as Na}from"./UploadImg-3538b5a5.js";import{__tla as Oa}from"./index-b59955b6.js";import{__tla as Pa}from"./el-image-viewer-dddb6285.js";import"./constants-e43f22dd.js";let N,za=Promise.all([(()=>{try{return ca}catch{}})(),(()=>{try{return ma}catch{}})(),(()=>{try{return da}catch{}})(),(()=>{try{return ya}catch{}})(),(()=>{try{return ba}catch{}})(),(()=>{try{return wa}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return Sa}catch{}})(),(()=>{try{return Ua}catch{}})(),(()=>{try{return Va}catch{}})(),(()=>{try{return Ma}catch{}})(),(()=>{try{return Da}catch{}})(),(()=>{try{return Na}catch{}})(),(()=>{try{return Oa}catch{}})(),(()=>{try{return Pa}catch{}})()]).then(async()=>{let v;v=["src"],N=I({name:"ProductBrand",__name:"index",setup(Ya){const k=Ta(),{t:O}=J(),y=p(!0),x=p(0),C=p([]),s=L({pageNo:1,pageSize:10,name:void 0,status:void 0,createTime:[]}),S=p(),n=async()=>{y.value=!0;try{const u=await va(s);C.value=u.list,x.value=u.total}finally{y.value=!1}},h=()=>{n()},P=()=>{S.value.resetFields(),h()},T=p(),U=(u,r)=>{T.value.open(u,r)};return X(()=>{n()}),(u,r)=>{const z=$,d=aa,Y=ea,B=ta,F=la,b=ra,c=sa,H=oa,V=fa,_=_a,q=ia,A=na,K=pa,g=E("hasPermi"),R=ua;return o(),w(M,null,[a(V,null,{default:l(()=>[a(H,{class:"-mb-15px",model:t(s),ref_key:"queryFormRef",ref:S,inline:!0,"label-width":"68px"},{default:l(()=>[a(d,{label:"\u54C1\u724C\u540D\u79F0",prop:"name"},{default:l(()=>[a(z,{modelValue:t(s).name,"onUpdate:modelValue":r[0]||(r[0]=e=>t(s).name=e),placeholder:"\u8BF7\u8F93\u5165\u54C1\u724C\u540D\u79F0",clearable:"",onKeyup:Q(h,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),a(d,{label:"\u72B6\u6001",prop:"status"},{default:l(()=>[a(B,{modelValue:t(s).status,"onUpdate:modelValue":r[1]||(r[1]=e=>t(s).status=e),placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001",clearable:"",class:"!w-240px"},{default:l(()=>[(o(!0),w(M,null,W(t(ha)(t(D).COMMON_STATUS),e=>(o(),m(Y,{key:e.value,label:e.label,value:e.value},null,8,["label","value"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(d,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"createTime"},{default:l(()=>[a(F,{modelValue:t(s).createTime,"onUpdate:modelValue":r[2]||(r[2]=e=>t(s).createTime=e),"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")],class:"!w-240px"},null,8,["modelValue","default-time"])]),_:1}),a(d,null,{default:l(()=>[a(c,{onClick:h},{default:l(()=>[a(b,{icon:"ep:search",class:"mr-5px"}),i(" \u641C\u7D22")]),_:1}),a(c,{onClick:P},{default:l(()=>[a(b,{icon:"ep:refresh",class:"mr-5px"}),i(" \u91CD\u7F6E")]),_:1}),f((o(),m(c,{type:"primary",plain:"",onClick:r[3]||(r[3]=e=>U("create"))},{default:l(()=>[a(b,{icon:"ep:plus",class:"mr-5px"}),i(" \u65B0\u589E ")]),_:1})),[[g,["product:brand:create"]]])]),_:1})]),_:1},8,["model"])]),_:1}),a(V,null,{default:l(()=>[f((o(),m(A,{data:t(C),"row-key":"id","default-expand-all":""},{default:l(()=>[a(_,{label:"\u54C1\u724C\u540D\u79F0",prop:"name",sortable:""}),a(_,{label:"\u54C1\u724C\u56FE\u7247",align:"center",prop:"picUrl"},{default:l(e=>[e.row.picUrl?(o(),w("img",{key:0,src:e.row.picUrl,alt:"\u54C1\u724C\u56FE\u7247",class:"h-30px"},null,8,v)):Z("",!0)]),_:1}),a(_,{label:"\u54C1\u724C\u6392\u5E8F",align:"center",prop:"sort"}),a(_,{label:"\u5F00\u542F\u72B6\u6001",align:"center",prop:"status"},{default:l(e=>[a(q,{type:t(D).COMMON_STATUS,value:e.row.status},null,8,["type","value"])]),_:1}),a(_,{label:"\u521B\u5EFA\u65F6\u95F4",align:"center",prop:"createTime",width:"180",formatter:t(ga)},null,8,["formatter"]),a(_,{label:"\u64CD\u4F5C",align:"center"},{default:l(e=>[f((o(),m(c,{link:"",type:"primary",onClick:j=>U("update",e.row.id)},{default:l(()=>[i(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[g,["product:brand:update"]]]),f((o(),m(c,{link:"",type:"danger",onClick:j=>(async G=>{try{await k.delConfirm(),await ka(G),k.success(O("common.delSuccess")),await n()}catch{}})(e.row.id)},{default:l(()=>[i(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[g,["product:brand:delete"]]])]),_:1})]),_:1},8,["data"])),[[R,t(y)]]),a(K,{total:t(x),page:t(s).pageNo,"onUpdate:page":r[4]||(r[4]=e=>t(s).pageNo=e),limit:t(s).pageSize,"onUpdate:limit":r[5]||(r[5]=e=>t(s).pageSize=e),onPagination:n},null,8,["total","page","limit"])]),_:1}),a(Ca,{ref_key:"formRef",ref:T,onSuccess:n},null,512)],64)}}})});export{za as __tla,N as default};