1 |
- import{d as O,h as q,r as m,e as G,l as H,Q as K,o,c as N,f as a,w as t,a as r,R as Q,n,x as p,v as d,g as j,F as B,V as E,A as J,j as L,C as W,D as $,G as X,H as Y,I as Z,_ as aa,__tla as ta}from"./index-bd9277a1.js";import{_ as ea,__tla as ra}from"./DictTag-d6503fab.js";import{_ as la,__tla as _a}from"./ContentWrap-7c73ab26.js";import{D as sa,__tla as oa}from"./dict-4b2e9fd3.js";import{h as na}from"./tree-0af4953a.js";import{d as ca,__tla as ia}from"./formatTime-8639ba1a.js";import{g as ua,d as ma,__tla as pa}from"./category-ca717d96.js";import da,{__tla as fa}from"./CategoryForm-40ff92f2.js";import{u as ya,__tla as ha}from"./useMessage-274788d4.js";import"./color-6e929987.js";import{__tla as wa}from"./ContentWrap.vue_vue_type_script_setup_true_lang-5f6a2d0d.js";import{__tla as ga}from"./el-card-bc8cec83.js";import{__tla as xa}from"./Dialog-eba103da.js";import{__tla as ka}from"./UploadImg-be688408.js";import{__tla as ba}from"./index-b80ba4d7.js";import{__tla as va}from"./el-image-viewer-995341ab.js";import"./constants-40f13f5e.js";let S,Ca=Promise.all([(()=>{try{return ta}catch{}})(),(()=>{try{return ra}catch{}})(),(()=>{try{return _a}catch{}})(),(()=>{try{return oa}catch{}})(),(()=>{try{return ia}catch{}})(),(()=>{try{return pa}catch{}})(),(()=>{try{return fa}catch{}})(),(()=>{try{return ha}catch{}})(),(()=>{try{return wa}catch{}})(),(()=>{try{return ga}catch{}})(),(()=>{try{return xa}catch{}})(),(()=>{try{return ka}catch{}})(),(()=>{try{return ba}catch{}})(),(()=>{try{return va}catch{}})()]).then(async()=>{let g;g=["src"],S=aa(O({name:"ProductCategory",__name:"index",setup(Ua){const x=ya(),{t:z}=q(),f=m(!0),k=m([]),c=G({name:void 0}),b=m(),i=async()=>{f.value=!0;try{const u=await ua(c);k.value=na(u,"id","parentId")}finally{f.value=!1}},y=()=>{i()},D=()=>{b.value.resetFields(),y()},v=m(),C=(u,l)=>{v.value.open(u,l)};return H(()=>{i()}),(u,l)=>{const F=E,U=J,h=L,s=W,M=$,V=la,_=X,P=ea,R=Y,w=K("hasPermi"),T=Z;return o(),N(B,null,[a(V,null,{default:t(()=>[a(M,{class:"-mb-15px",model:r(c),ref_key:"queryFormRef",ref:b,inline:!0,"label-width":"68px"},{default:t(()=>[a(U,{label:"\u5206\u7C7B\u540D\u79F0",prop:"name"},{default:t(()=>[a(F,{modelValue:r(c).name,"onUpdate:modelValue":l[0]||(l[0]=e=>r(c).name=e),placeholder:"\u8BF7\u8F93\u5165\u5206\u7C7B\u540D\u79F0",clearable:"",onKeyup:Q(y,["enter"]),class:"!w-240px"},null,8,["modelValue"])]),_:1}),a(U,null,{default:t(()=>[a(s,{onClick:y},{default:t(()=>[a(h,{icon:"ep:search",class:"mr-5px"}),n(" \u641C\u7D22")]),_:1}),a(s,{onClick:D},{default:t(()=>[a(h,{icon:"ep:refresh",class:"mr-5px"}),n(" \u91CD\u7F6E")]),_:1}),p((o(),d(s,{type:"primary",plain:"",onClick:l[1]||(l[1]=e=>C("create"))},{default:t(()=>[a(h,{icon:"ep:plus",class:"mr-5px"}),n(" \u65B0\u589E ")]),_:1})),[[w,["product:category:create"]]])]),_:1})]),_:1},8,["model"])]),_:1}),a(V,null,{default:t(()=>[p((o(),d(R,{data:r(k),"row-key":"id","default-expand-all":""},{default:t(()=>[a(_,{label:"\u540D\u79F0","min-width":"240",prop:"name",sortable:""}),a(_,{label:"\u5206\u7C7B\u56FE\u6807",align:"center","min-width":"80",prop:"picUrl"},{default:t(e=>[j("img",{src:e.row.picUrl,alt:"\u79FB\u52A8\u7AEF\u5206\u7C7B\u56FE",class:"h-36px"},null,8,g)]),_:1}),a(_,{label:"\u6392\u5E8F",align:"center","min-width":"150",prop:"sort"}),a(_,{label:"\u72B6\u6001",align:"center","min-width":"150",prop:"status"},{default:t(e=>[a(P,{type:r(sa).COMMON_STATUS,value:e.row.status},null,8,["type","value"])]),_:1}),a(_,{label:"\u521B\u5EFA\u65F6\u95F4",align:"center",prop:"createTime",width:"180",formatter:r(ca)},null,8,["formatter"]),a(_,{label:"\u64CD\u4F5C",align:"center"},{default:t(e=>[p((o(),d(s,{link:"",type:"primary",onClick:A=>C("update",e.row.id)},{default:t(()=>[n(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[w,["product:category:update"]]]),p((o(),d(s,{link:"",type:"danger",onClick:A=>(async I=>{try{await x.delConfirm(),await ma(I),x.success(z("common.delSuccess")),await i()}catch{}})(e.row.id)},{default:t(()=>[n(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[w,["product:category:delete"]]])]),_:1})]),_:1},8,["data"])),[[T,r(f)]])]),_:1}),a(da,{ref_key:"formRef",ref:v,onSuccess:i},null,512)],64)}}}),[["__file","D:/zhongxing/mall-newfeifan-zx-admin/src/views/mall/product/category/index.vue"]])});export{Ca as __tla,S as default};
|