data_center/public/admin/assets/index.7aa376bf.js

2 lines
7.9 KiB
JavaScript

import{B as Y,C as Z,M as ee,N as te,w as le,D as ae,I as oe,O as ue,P as ne,Q as se}from"./element-plus.9c2fdfa8.js";import{_ as ie}from"./index.vue_vue_type_script_setup_true_lang.261df48b.js";import{f as pe,b as de,d as re}from"./index.b57b84f0.js";import{u as me}from"./vue-router.e2f4a118.js";import{u as ce}from"./usePaging.c22e2b6f.js";import{u as _e}from"./useDictOptions.773276bb.js";import{b as fe,a as ye,g as be}from"./task_template.9de5142a.js";import{d as I,s as Fe,r as k,$ as U,af as ve,o as n,c as V,U as a,L as o,M as v,u as e,K as i,Q as Be,T as q,a7 as L,R as b,a as D,S as ke,k as we,n as P}from"./@vue.53f8d7c3.js";import"./lodash.5512e984.js";import{_ as Ee}from"./edit.vue_vue_type_script_setup_true_name_taskTemplateEdit_lang.0d3b23db.js";import{_ as Ce}from"./edit_admin.vue_vue_type_script_setup_true_name_taskTemplateEdit_lang.7dce65d6.js";import{_ as Ve}from"./edit_village.vue_vue_type_script_setup_true_name_taskTemplateEdit_lang.606aa847.js";import"./@vueuse.038954e7.js";import"./@element-plus.37f92579.js";import"./lodash-es.29c53eac.js";import"./dayjs.e873ead7.js";import"./@amap.8a62addd.js";import"./async-validator.fb49d0f5.js";import"./@ctrl.82a509e0.js";import"./@popperjs.36402333.js";import"./escape-html.e5dfadb9.js";import"./normalize-wheel-es.8aeb3683.js";import"./axios.92474d72.js";import"./pinia.bd103f5d.js";import"./vue-demi.ebc8116b.js";import"./css-color-function.ee641d3d.js";import"./color.cbc2f3a9.js";import"./clone.7fddbad2.js";import"./color-convert.755d189f.js";import"./color-name.e7a4e1d3.js";import"./color-string.e356f5de.js";import"./balanced-match.d2a36341.js";import"./debug.a7d78d4d.js";import"./ms.a9ae1d6d.js";import"./nprogress.f73355d0.js";import"./vue-clipboard3.dca5bca3.js";import"./clipboard.16e4491b.js";import"./echarts.8d7a50ae.js";import"./zrender.1084fa23.js";import"./tslib.60310f1a.js";import"./highlight.js.4ebdf9a4.js";import"./@highlightjs.9cf3e967.js";import"./index.3fc23cf2.js";import"./index.vue_vue_type_style_index_0_scoped_187b1ead_lang.33043b78.js";import"./map.vue_vue_type_script_setup_true_name_taskTemplateEdit_lang.437ca914.js";import"./dialog_index_personnel.vue_vue_type_script_setup_true_name_companyLists_lang.a3c547b1.js";import"./role.38f9c5c3.js";import"./dialog_commodity.vue_vue_type_script_setup_true_name_companyLists_lang.d10cf6ff.js";const De={class:"mt-4"},xe={class:"flex mt-4 justify-end"},he=I({name:"taskTemplateLists"}),ge=I({...he,setup(Ae){var g,A,T;const r=Fe(),x=k([]),d=k(!1),_=me(),u=U({id:"",company_id:"",title:"",admin_id:"",money:"",type:"",status:"",content:""}),w=k(10);(g=_.query)!=null&&g.id&&(u.id=_.query.id),(A=_.query)!=null&&A.company_id&&(u.company_id=_.query.company_id),(T=_.query)!=null&&T.company_type&&(w.value=_.query.company_type);const N=U([{id:1,name:"\u663E\u793A"},{id:2,name:"\u9690\u85CF"}]),E=k([]),M=s=>{E.value=s.map(({id:t})=>t)},{dictData:C}=_e(""),{pager:F,getLists:f,resetParams:O,resetPage:Q}=ce({fetchFun:ye,params:u}),j=async()=>{var s,t;d.value=!0,await P(),(s=r.value)==null||s.open("add"),(t=r.value)==null||t.setFormData({company_id:u.company_id})},K=async s=>{var t,m;d.value=!0,await P(),(t=r.value)==null||t.open("edit"),(m=r.value)==null||m.setFormData(s)},h=async s=>{await pe.confirm("\u786E\u5B9A\u8981\u5220\u9664\uFF1F"),await be({id:s}),f()};return fe({type_id:10}).then(s=>{x.value=s.lists}),f(),(s,t)=>{const m=Y,c=Z,$=ee,S=te,y=le,z=ae,R=oe,G=de,p=ue,H=ne,J=ie,B=ve("perms"),W=se;return n(),V("div",null,[a(R,{class:"!border-none mb-4",shadow:"never"},{default:o(()=>[a(z,{class:"mb-[-16px] formtabel",model:e(u),inline:""},{default:o(()=>[a(c,{"label-width":"100px",label:"\u4EFB\u52A1\u540D\u79F0",prop:"title"},{default:o(()=>[a(m,{class:"w-[280px]",modelValue:e(u).title,"onUpdate:modelValue":t[0]||(t[0]=l=>e(u).title=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u4EFB\u52A1\u540D\u79F0"},null,8,["modelValue"])]),_:1}),a(c,{"label-width":"100px",label:"\u521B\u5EFA\u4EBA",prop:"admin_id"},{default:o(()=>[a(m,{class:"w-[280px]",modelValue:e(u).admin_id,"onUpdate:modelValue":t[1]||(t[1]=l=>e(u).admin_id=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u521B\u5EFA\u4EBA"},null,8,["modelValue"])]),_:1}),a(c,{"label-width":"100px",label:"\u91D1\u989D",prop:"money"},{default:o(()=>[a(m,{class:"w-[280px]",modelValue:e(u).money,"onUpdate:modelValue":t[2]||(t[2]=l=>e(u).money=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u91D1\u989D"},null,8,["modelValue"])]),_:1}),a(c,{"label-width":"100px",label:"\u4EFB\u52A1\u7C7B\u578B",prop:"type"},{default:o(()=>[a(S,{modelValue:e(u).type,"onUpdate:modelValue":t[3]||(t[3]=l=>e(u).type=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u4EFB\u52A1\u7C7B\u578B"},{default:o(()=>[(n(!0),V(q,null,L(e(x),l=>(n(),i($,{key:l.label,value:l.id,label:l.name},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(c,{"label-width":"100px",label:"\u72B6\u6001",prop:"status"},{default:o(()=>[a(S,{modelValue:e(u).status,"onUpdate:modelValue":t[4]||(t[4]=l=>e(u).status=l),clearable:"",placeholder:"\u8BF7\u9009\u62E9\u72B6\u6001"},{default:o(()=>[(n(!0),V(q,null,L(e(N),l=>(n(),i($,{key:l.label,value:l.id,label:l.name},null,8,["value","label"]))),128))]),_:1},8,["modelValue"])]),_:1}),a(c,{"label-width":"100px",label:"\u4EFB\u52A1\u63CF\u8FF0",prop:"content"},{default:o(()=>[a(m,{class:"w-[280px]",modelValue:e(u).content,"onUpdate:modelValue":t[5]||(t[5]=l=>e(u).content=l),clearable:"",placeholder:"\u8BF7\u8F93\u5165\u4EFB\u52A1\u63CF\u8FF0"},null,8,["modelValue"])]),_:1}),a(c,{"label-width":"100px",label:""},{default:o(()=>[a(y,{class:"el-btn",type:"primary",onClick:e(Q)},{default:o(()=>[b("\u67E5\u8BE2")]),_:1},8,["onClick"]),a(y,{onClick:e(O)},{default:o(()=>[b("\u91CD\u7F6E")]),_:1},8,["onClick"])]),_:1})]),_:1},8,["model"])]),_:1}),v((n(),i(R,{class:"!border-none",shadow:"never"},{default:o(()=>[v((n(),i(y,{type:"primary",onClick:j},{icon:o(()=>[a(G,{name:"el-icon-Plus"})]),default:o(()=>[b(" \u65B0\u589E ")]),_:1})),[[B,["task_template.task_template/add"]]]),v((n(),i(y,{disabled:!e(E).length,onClick:t[6]||(t[6]=l=>h(e(E)))},{default:o(()=>[b(" \u5220\u9664 ")]),_:1},8,["disabled"])),[[B,["task_template.task_template/delete"]]]),D("div",De,[a(H,{data:e(F).lists,onSelectionChange:M},{default:o(()=>[a(p,{type:"selection",width:"55"}),a(p,{label:"ID",width:"80",prop:"id","show-overflow-tooltip":""}),a(p,{label:"\u4EFB\u52A1\u540D\u79F0",prop:"title","show-overflow-tooltip":""}),a(p,{label:"\u521B\u5EFA\u4EBA",prop:"admin_name","show-overflow-tooltip":""}),a(p,{label:"\u91D1\u989D",prop:"money","show-overflow-tooltip":""}),a(p,{label:"\u4EFB\u52A1\u7C7B\u578B",prop:"type_name","show-overflow-tooltip":""}),a(p,{label:"\u72B6\u6001","show-overflow-tooltip":""},{default:o(({row:l})=>[D("span",null,ke(l.status==1?"\u663E\u793A":"\u9690\u85CF"),1)]),_:1}),a(p,{label:"\u4EFB\u52A1\u63CF\u8FF0",prop:"content","show-overflow-tooltip":""}),a(p,{label:"\u64CD\u4F5C",width:"120",fixed:"right"},{default:o(({row:l})=>[v((n(),i(y,{type:"primary",link:"",onClick:X=>K(l)},{default:o(()=>[b(" \u7F16\u8F91 ")]),_:2},1032,["onClick"])),[[B,["task_template.task_template/edit"]]]),v((n(),i(y,{type:"danger",link:"",onClick:X=>h(l.id)},{default:o(()=>[b(" \u5220\u9664 ")]),_:2},1032,["onClick"])),[[B,["task_template.task_template/delete"]]])]),_:1})]),_:1},8,["data"])]),D("div",xe,[a(J,{modelValue:e(F),"onUpdate:modelValue":t[7]||(t[7]=l=>we(F)?F.value=l:null),onChange:e(f)},null,8,["modelValue","onChange"])])]),_:1})),[[W,e(F).loading]]),e(d)&&e(w)==41?(n(),i(Ce,{key:0,ref_key:"editRef",ref:r,"dict-data":e(C),onSuccess:e(f),onClose:t[8]||(t[8]=l=>d.value=!1)},null,8,["dict-data","onSuccess"])):e(d)&&e(w)==17?(n(),i(Ve,{key:1,ref_key:"editRef",ref:r,"dict-data":e(C),onSuccess:e(f),onClose:t[9]||(t[9]=l=>d.value=!1)},null,8,["dict-data","onSuccess"])):e(d)?(n(),i(Ee,{key:2,ref_key:"editRef",ref:r,"dict-data":e(C),onSuccess:e(f),onClose:t[10]||(t[10]=l=>d.value=!1)},null,8,["dict-data","onSuccess"])):Be("",!0)])}}});const Vt=re(ge,[["__scopeId","data-v-e7c2eb5c"]]);export{Vt as default};