multiStoreAdmin/build/store/assets/index.8c6a0891.js

2 lines
3.8 KiB
JavaScript

import{L as S,J as N,w as R,M as T,t as L,N as U,O as P}from"./element-plus.ab0703f2.js";import{_ as j}from"./index.vue_vue_type_script_setup_true_lang.5fc87b57.js";import{f as z,b as J}from"./index.5ab034a5.js";import{d as M,e as O,f as Q}from"./article.83a523ba.js";import{u as W}from"./usePaging.fff444fa.js";import{_ as q}from"./edit.vue_vue_type_script_setup_true_lang.684fbb34.js";import{d as F,s as G,r as H,ap as I,o as n,c as K,W as t,Q as i,R as p,u as s,P as d,a as w,U as h,j as X,T as Y,n as g}from"./@vue.340249d8.js";import"./lodash-es.edba6135.js";import"./@vueuse.e3650918.js";import"./@element-plus.558a564d.js";import"./@popperjs.36402333.js";import"./@ctrl.b082b0c1.js";import"./dayjs.9886411c.js";import"./axios.45058a27.js";import"./async-validator.fb49d0f5.js";import"./memoize-one.4ee5c96d.js";import"./normalize-wheel-es.8aeb3683.js";import"./@floating-ui.0f9ce7c3.js";import"./lodash.3d784a58.js";import"./vue-router.9ddb0e92.js";import"./pinia.97fe9b12.js";import"./css-color-function.5c1c877d.js";import"./color.97e03886.js";import"./clone.cfa55f7b.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.8c276ac9.js";import"./vue-clipboard3.44194d32.js";import"./clipboard.47836ecb.js";import"./echarts.8535e5a6.js";import"./zrender.3eba8991.js";import"./tslib.60310f1a.js";import"./highlight.js.31cd7941.js";import"./@highlightjs.309a94da.js";import"./index.5670c3d4.js";const Z={class:"flex justify-end mt-4"},ee=F({name:"articleColumn"}),ze=F({...ee,setup(te){const _=G(),f=H(!1),{pager:r,getLists:l}=W({fetchFun:Q}),b=async()=>{var o;f.value=!0,await g(),(o=_.value)==null||o.open("add")},k=async o=>{var e,u;f.value=!0,await g(),(e=_.value)==null||e.open("edit"),(u=_.value)==null||u.getDetail(o)},y=async o=>{await z.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await M({id:o}),l()},A=async(o,e)=>{try{await O({id:e,is_show:o}),l()}catch{l()}};return l(),(o,e)=>{const u=S,E=N,B=J,v=R,c=T,V=L,D=U,x=j,C=I("perms"),$=P;return n(),K("div",null,[t(E,{class:"!border-none",shadow:"never"},{default:i(()=>[t(u,{type:"warning",title:"\u6E29\u99A8\u63D0\u793A\uFF1A\u7528\u4E8E\u7BA1\u7406\u7F51\u7AD9\u7684\u5206\u7C7B\uFF0C\u53EA\u53EF\u6DFB\u52A0\u5230\u4E00\u7EA7",closable:!1,"show-icon":""})]),_:1}),p((n(),d(E,{class:"!border-none mt-4",shadow:"never"},{default:i(()=>[w("div",null,[p((n(),d(v,{class:"mb-4",type:"primary",onClick:e[0]||(e[0]=a=>b())},{icon:i(()=>[t(B,{name:"el-icon-Plus"})]),default:i(()=>[h(" \u65B0\u589E ")]),_:1})),[[C,["article.articleCate/add"]]])]),t(D,{size:"large",data:s(r).lists},{default:i(()=>[t(c,{label:"\u680F\u76EE\u540D\u79F0",prop:"name","min-width":"120"}),t(c,{label:"\u6587\u7AE0\u6570",prop:"article_count","min-width":"120"}),t(c,{label:"\u72B6\u6001","min-width":"120"},{default:i(({row:a})=>[p(t(V,{modelValue:a.is_show,"onUpdate:modelValue":m=>a.is_show=m,"active-value":1,"inactive-value":0,onChange:m=>A(m,a.id)},null,8,["modelValue","onUpdate:modelValue","onChange"]),[[C,["article.articleCate/updateStatus"]]])]),_:1}),t(c,{label:"\u6392\u5E8F",prop:"sort","min-width":"120"}),t(c,{label:"\u64CD\u4F5C",width:"120",fixed:"right"},{default:i(({row:a})=>[p((n(),d(v,{type:"primary",link:"",onClick:m=>k(a)},{default:i(()=>[h(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[C,["article.articleCate/edit"]]]),p((n(),d(v,{type:"danger",link:"",onClick:m=>y(a.id)},{default:i(()=>[h(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[C,["article.articleCate/delete"]]])]),_:1})]),_:1},8,["data"]),w("div",Z,[t(x,{modelValue:s(r),"onUpdate:modelValue":e[1]||(e[1]=a=>X(r)?r.value=a:null),onChange:s(l)},null,8,["modelValue","onChange"])])]),_:1})),[[$,s(r).loading]]),s(f)?(n(),d(q,{key:0,ref_key:"editRef",ref:_,onSuccess:s(l),onClose:e[2]||(e[2]=a=>f.value=!1)},null,8,["onSuccess"])):Y("",!0)])}}});export{ze as default};