moreShopAdmin/build/admin/assets/index.6733be9a.js

2 lines
5.6 KiB
JavaScript

import{$ as h,C as z,D as J,J as Q,K as Z,w as G,F as H,L as W,M as X,N as Y,O as ee}from"./element-plus.91c68cc0.js";import{_ as te}from"./index.vue_vue_type_script_setup_true_lang.863ae816.js";import{e as oe,f as le,b as ae}from"./index.892cd835.js";import{d as R,s as ne,r as x,Z as ie,af as se,ap as ue,o as n,c as T,U as t,L as o,u as l,aa as $,R as s,a as B,M as m,K as d,j as re,Q as de,n as K}from"./@vue.76ce7aa3.js";import{i as pe,e as me}from"./dict.6d1cdd59.js";import{u as ce}from"./usePaging.f8c888e4.js";import{_ as _e}from"./edit.vue_vue_type_script_setup_true_lang.cb2a3a41.js";import"./lodash-es.f52bd8b1.js";import"./async-validator.fb49d0f5.js";import"./@vueuse.9ffef7f8.js";import"./@element-plus.73235148.js";import"./dayjs.0112e2c7.js";import"./@babel.80d29b7b.js";import"./@ctrl.b082b0c1.js";import"./normalize-wheel-es.8aeb3683.js";import"./@popperjs.36402333.js";import"./lodash.4e6d2a38.js";import"./axios.659d5af3.js";import"./jspdf.6c61b9d3.js";import"./fflate.0418c72f.js";import"./vue-router.10bd5b90.js";import"./pinia.f3529286.js";import"./css-color-function.bb8c34b2.js";import"./color.fbd63fe8.js";import"./clone.31a3aa2c.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./ms.564e106c.js";import"./nprogress.b502f541.js";import"./vue-clipboard3.e775fc74.js";import"./clipboard.6417898a.js";import"./echarts.5016c48c.js";import"./zrender.58d022a1.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.8d65305c.js";import"./index.c6e6b480.js";import"./index.vue_vue_type_style_index_0_scoped_d380c88d_lang.cf0d972e.js";const fe={class:"dict-type"},ye={class:"mt-4"},ve={class:"flex justify-end mt-4"},Ce=R({name:"dictType"}),it=R({...Ce,setup(ge){const y=ne(),v=x(!1),u=ie({name:"",type:"",status:""}),{pager:c,getLists:C,resetPage:b,resetParams:P}=ce({fetchFun:me,params:u}),k=x([]),L=i=>{k.value=i.map(({id:e})=>e)},N=async()=>{var i;v.value=!0,await K(),(i=y.value)==null||i.open("add")},S=async i=>{var e,_;v.value=!0,await K(),(e=y.value)==null||e.open("edit"),(_=y.value)==null||_.setFormData(i)},w=async i=>{await le.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await pe({id:i}),C()};return C(),(i,e)=>{const _=z,g=J,E=Q,U=Z,p=G,A=H,F=W,V=ae,r=X,D=h,I=se("router-link"),j=Y,q=te,f=ue("perms"),M=ee;return n(),T("div",fe,[t(F,{class:"!border-none",shadow:"never"},{default:o(()=>[t(A,{ref:"formRef",class:"mb-[-16px]",model:l(u),inline:""},{default:o(()=>[t(g,{label:"\u5B57\u5178\u540D\u79F0"},{default:o(()=>[t(_,{class:"w-[280px]",modelValue:l(u).name,"onUpdate:modelValue":e[0]||(e[0]=a=>l(u).name=a),clearable:"",onKeyup:$(l(b),["enter"])},null,8,["modelValue","onKeyup"])]),_:1}),t(g,{label:"\u5B57\u5178\u7C7B\u578B"},{default:o(()=>[t(_,{class:"w-[280px]",modelValue:l(u).type,"onUpdate:modelValue":e[1]||(e[1]=a=>l(u).type=a),clearable:"",onKeyup:$(l(b),["enter"])},null,8,["modelValue","onKeyup"])]),_:1}),t(g,{label:"\u72B6\u6001"},{default:o(()=>[t(U,{class:"w-[280px]",modelValue:l(u).status,"onUpdate:modelValue":e[2]||(e[2]=a=>l(u).status=a)},{default:o(()=>[t(E,{label:"\u5168\u90E8",value:""}),t(E,{label:"\u6B63\u5E38",value:1}),t(E,{label:"\u505C\u7528",value:0})]),_:1},8,["modelValue"])]),_:1}),t(g,null,{default:o(()=>[t(p,{type:"primary",onClick:l(b)},{default:o(()=>e[6]||(e[6]=[s("\u67E5\u8BE2")])),_:1},8,["onClick"]),t(p,{onClick:l(P)},{default:o(()=>e[7]||(e[7]=[s("\u91CD\u7F6E")])),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),t(F,{class:"!border-none mt-4",shadow:"never"},{default:o(()=>[B("div",null,[m((n(),d(p,{type:"primary",onClick:N},{icon:o(()=>[t(V,{name:"el-icon-Plus"})]),default:o(()=>[e[8]||(e[8]=s(" \u65B0\u589E "))]),_:1})),[[f,["setting.dict.dict_type/add"]]]),m((n(),d(p,{disabled:!l(k).length,type:"danger",onClick:e[3]||(e[3]=a=>w(l(k)))},{icon:o(()=>[t(V,{name:"el-icon-Delete"})]),default:o(()=>[e[9]||(e[9]=s(" \u5220\u9664 "))]),_:1},8,["disabled"])),[[f,["setting.dict.dict_type/delete"]]])]),m((n(),T("div",ye,[B("div",null,[t(j,{data:l(c).lists,size:"large",onSelectionChange:L},{default:o(()=>[t(r,{type:"selection",width:"55"}),t(r,{label:"ID",prop:"id"}),t(r,{label:"\u5B57\u5178\u540D\u79F0",prop:"name","min-width":"120"}),t(r,{label:"\u5B57\u5178\u7C7B\u578B",prop:"type","min-width":"120"}),t(r,{label:"\u72B6\u6001"},{default:o(({row:a})=>[a.status==1?(n(),d(D,{key:0},{default:o(()=>e[10]||(e[10]=[s("\u6B63\u5E38")])),_:1})):(n(),d(D,{key:1,type:"danger"},{default:o(()=>e[11]||(e[11]=[s("\u505C\u7528")])),_:1}))]),_:1}),t(r,{label:"\u5907\u6CE8",prop:"remark","show-tooltip-when-overflow":""}),t(r,{label:"\u521B\u5EFA\u65F6\u95F4",prop:"create_time","min-width":"180"}),t(r,{label:"\u64CD\u4F5C",width:"190",fixed:"right"},{default:o(({row:a})=>[m((n(),d(p,{link:"",type:"primary",onClick:O=>S(a)},{default:o(()=>e[12]||(e[12]=[s(" \u7F16\u8F91 ")])),_:2},1032,["onClick"])),[[f,["setting.dict.dict_type/edit"]]]),m((n(),d(p,{type:"primary",link:""},{default:o(()=>[t(I,{to:{path:l(oe)("setting.dict.dict_data/lists"),query:{id:a.id}}},{default:o(()=>e[13]||(e[13]=[s(" \u6570\u636E\u7BA1\u7406 ")])),_:2},1032,["to"])]),_:2},1024)),[[f,["setting.dict.dict_data/lists"]]]),m((n(),d(p,{link:"",type:"danger",onClick:O=>w(a.id)},{default:o(()=>e[14]||(e[14]=[s(" \u5220\u9664 ")])),_:2},1032,["onClick"])),[[f,["setting.dict.dict_type/delete"]]])]),_:1})]),_:1},8,["data"])]),B("div",ve,[t(q,{modelValue:l(c),"onUpdate:modelValue":e[4]||(e[4]=a=>re(c)?c.value=a:null),onChange:l(C)},null,8,["modelValue","onChange"])])])),[[M,l(c).loading]])]),_:1}),l(v)?(n(),d(_e,{key:0,ref_key:"editRef",ref:y,onSuccess:l(C),onClose:e[5]||(e[5]=a=>v.value=!1)},null,8,["onSuccess"])):de("",!0)])}}});export{it as default};