2 lines
5.1 KiB
JavaScript
2 lines
5.1 KiB
JavaScript
import{a6 as A,B as I,C as M,M as O,N as Q,w as q,D as G,I as H,O as J,P as W,Q as X}from"./element-plus.9816852d.js";import{_ as Y}from"./index.vue_vue_type_script_setup_true_lang.f99137a4.js";import{f as Z,b as ee}from"./index.4eaf9bd5.js";import{_ as te}from"./index.vue_vue_type_script_setup_true_lang.9e853294.js";import{d as h,s as oe,r as ae,$ as le,af as se,o as r,c as ne,U as e,L as o,u as t,a8 as g,R as m,a as k,M as v,K as c,S as ue,k as ie,Q as re,n as D}from"./@vue.51d7f2d8.js";import{c as V,d as me}from"./post.ac4c2ff4.js";import{u as pe}from"./usePaging.2ad8e1e6.js";import{_ as de}from"./edit.vue_vue_type_script_setup_true_lang.122304ed.js";import"./@vueuse.ec90c285.js";import"./@element-plus.a074d1f6.js";import"./lodash-es.29c53eac.js";import"./dayjs.576af3ba.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.b082b0c1.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./lodash.675f209e.js";import"./axios.54f807ba.js";import"./vue-router.9f65afb1.js";import"./pinia.56356cb7.js";import"./vue-demi.b3a9cad9.js";import"./css-color-function.0a5c0f85.js";import"./color.e5eb3bba.js";import"./clone.546d9b81.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.aee266dc.js";import"./ms.a9ae1d6d.js";import"./nprogress.f73355d0.js";import"./vue-clipboard3.dca5bca3.js";import"./clipboard.16e4491b.js";import"./echarts.ac57a99a.js";import"./zrender.d54ce080.js";import"./tslib.60310f1a.js";import"./highlight.js.dba6fa1b.js";import"./@highlightjs.40d5feba.js";import"./index.2d3a3dd9.js";import"./index.vue_vue_type_style_index_0_scoped_95d1884e_lang.0fc4c9f8.js";const ce={class:"post-lists"},_e={class:"flex justify-end mt-4"},fe=h({name:"post"}),st=h({...fe,setup(be){const _=oe(),f=ae(!1),s=le({code:"",name:"",status:""}),{pager:i,getLists:b,resetPage:F,resetParams:B}=pe({fetchFun:V,params:s}),x=async()=>{var n;f.value=!0,await D(),(n=_.value)==null||n.open("add")},$=async n=>{var a,p;f.value=!0,await D(),(a=_.value)==null||a.open("edit"),(p=_.value)==null||p.getDetail(n)},j=async n=>{await Z.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await me({id:n}),b()};return b(),(n,a)=>{const p=I,C=M,w=O,K=Q,d=q,P=te,R=G,E=H,N=ee,u=J,S=A,T=W,U=Y,y=se("perms"),z=X;return r(),ne("div",ce,[e(E,{class:"!border-none",shadow:"never"},{default:o(()=>[e(R,{ref:"formRef",class:"mb-[-16px]",model:t(s),inline:!0},{default:o(()=>[e(C,{label:"\u5C97\u4F4D\u7F16\u7801"},{default:o(()=>[e(p,{class:"w-[280px]",modelValue:t(s).code,"onUpdate:modelValue":a[0]||(a[0]=l=>t(s).code=l),clearable:"",onKeyup:g(t(F),["enter"])},null,8,["modelValue","onKeyup"])]),_:1}),e(C,{label:"\u5C97\u4F4D\u540D\u79F0"},{default:o(()=>[e(p,{class:"w-[280px]",modelValue:t(s).name,"onUpdate:modelValue":a[1]||(a[1]=l=>t(s).name=l),clearable:"",onKeyup:g(t(F),["enter"])},null,8,["modelValue","onKeyup"])]),_:1}),e(C,{label:"\u5C97\u4F4D\u72B6\u6001"},{default:o(()=>[e(K,{class:"w-[280px]",modelValue:t(s).status,"onUpdate:modelValue":a[2]||(a[2]=l=>t(s).status=l)},{default:o(()=>[e(w,{label:"\u5168\u90E8",value:""}),e(w,{label:"\u6B63\u5E38",value:1}),e(w,{label:"\u505C\u7528",value:0})]),_:1},8,["modelValue"])]),_:1}),e(C,null,{default:o(()=>[e(d,{type:"primary",onClick:t(F)},{default:o(()=>[m("\u67E5\u8BE2")]),_:1},8,["onClick"]),e(d,{onClick:t(B)},{default:o(()=>[m("\u91CD\u7F6E")]),_:1},8,["onClick"]),e(P,{class:"ml-2.5","fetch-fun":t(V),params:t(s),"page-size":t(i).size},null,8,["fetch-fun","params","page-size"])]),_:1})]),_:1},8,["model"])]),_:1}),e(E,{class:"!border-none mt-4",shadow:"never"},{default:o(()=>[k("div",null,[v((r(),c(d,{type:"primary",onClick:a[3]||(a[3]=l=>x())},{icon:o(()=>[e(N,{name:"el-icon-Plus"})]),default:o(()=>[m(" \u65B0\u589E ")]),_:1})),[[y,["dept.jobs/add"]]])]),v((r(),c(T,{class:"mt-4",size:"large",data:t(i).lists},{default:o(()=>[e(u,{label:"\u5C97\u4F4D\u7F16\u7801",prop:"code","min-width":"100"}),e(u,{label:"\u5C97\u4F4D\u540D\u79F0",prop:"name","min-width":"100"}),e(u,{label:"\u6392\u5E8F",prop:"sort","min-width":"100"}),e(u,{label:"\u5907\u6CE8",prop:"remark","min-width":"100","show-overflow-tooltip":""}),e(u,{label:"\u6DFB\u52A0\u65F6\u95F4",prop:"create_time","min-width":"180"}),e(u,{label:"\u72B6\u6001",prop:"status","min-width":"100"},{default:o(({row:l})=>[e(S,{class:"ml-2",type:l.status?"":"danger"},{default:o(()=>[m(ue(l.status_desc),1)]),_:2},1032,["type"])]),_:1}),e(u,{label:"\u64CD\u4F5C",width:"120",fixed:"right"},{default:o(({row:l})=>[v((r(),c(d,{type:"primary",link:"",onClick:L=>$(l)},{default:o(()=>[m(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[y,["dept.jobs/edit"]]]),v((r(),c(d,{type:"danger",link:"",onClick:L=>j(l.id)},{default:o(()=>[m(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[y,["dept.jobs/delete"]]])]),_:1})]),_:1},8,["data"])),[[z,t(i).loading]]),k("div",_e,[e(U,{modelValue:t(i),"onUpdate:modelValue":a[4]||(a[4]=l=>ie(i)?i.value=l:null),onChange:t(b)},null,8,["modelValue","onChange"])])]),_:1}),t(f)?(r(),c(de,{key:0,ref_key:"editRef",ref:_,onSuccess:t(b),onClose:a[5]||(a[5]=l=>f.value=!1)},null,8,["onSuccess"])):re("",!0)])}}});export{st as default};
|