You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

2 lines
3.0 KiB
JavaScript

var x=(C,d,t)=>new Promise((u,m)=>{var f=o=>{try{a(t.next(o))}catch(i){m(i)}},l=o=>{try{a(t.throw(o))}catch(i){m(i)}},a=o=>o.done?u(o.value):Promise.resolve(o.value).then(f,l);a((t=t.apply(C,d)).next())});import{P as E}from"./index-BOexY1T-.js";import{u as D,_ as T}from"./useTable--thsDsLA.js";import{_ as $}from"./index-B4wZYO02.js";import{c as I,f as P,a as B,b as M,d as k,_ as N}from"./CategoryRecordModal.vue_vue_type_script_setup_true_lang-VAO63bG2.js";import{b as S}from"./download-Da_OLLnH.js";import{u as V}from"./index-DVEqH4Di.js";import{I as v}from"./entry/index-CwTXVJ2d-1723001953242.js";import{d as L,aa as A,n as F,_ as n,a8 as s,a9 as r,k as w,u as e,m as b,G as h,ac as G}from"./vue-aEZWZQSa.js";import"./useContentViewHeight-C-BEyhbS.js";import"./useWindowSizeFn-C93ItSr2.js";import"./antd-BY-1PcYE.js";import"./onMountedOrActivated-BIJ0U1R1.js";import"./useForm-Ca7JThS8.js";import"./FormItem.vue_vue_type_script_lang-DhGC9etS.js";import"./componentMap-S705cJLS.js";import"./RadioButtonGroup.vue_vue_type_script_setup_true_lang-Cx2YeHC7.js";import"./copyTextToClipboard-BBFF3Y3I.js";import"./style-DTWqfx8n.js";import"./helper-BPjqq6ZQ.js";import"./BasicForm.vue_vue_type_style_index_0_lang-D34fDasZ.js";import"./sortable.esm-CnNXHMH-.js";import"./useSortable-BAwH_r98.js";import"./useLoading-B4X4QuoY.js";const ce=L({name:"CategoryRecord",__name:"index",setup(C){const[d,{reload:t,multipleRemove:u,selected:m}]=D({rowSelection:{type:"checkbox"},title:"分类别评估记录列表",api:I,showIndexColumn:!1,rowKey:"id",useSearchForm:!0,formConfig:{schemas:P,baseColProps:{xs:24,sm:24,md:24,lg:6}},columns:B,actionColumn:{width:200,title:"操作",key:"action",fixed:"right"}}),[f,{openModal:l}]=V();function a(p){l(!0,{record:p,update:!0})}function o(){l(!0,{update:!1})}function i(p){return x(this,null,function*(){yield k([p.id]),yield t()})}return(p,c)=>{const g=A("a-button"),y=F("auth");return n(),s(e(E),{dense:""},{default:r(()=>[w(e(T),{onRegister:e(d)},{toolbar:r(()=>[b((n(),s(g,{onClick:c[0]||(c[0]=_=>e(S)(e(M),"分类别评估记录数据"))},{default:r(()=>[h("导出")]),_:1})),[[y,"report:categoryRecord:export"]]),b((n(),s(g,{type:"primary",danger:"",onClick:c[1]||(c[1]=_=>e(u)(e(k))),disabled:!e(m)},{default:r(()=>[h("删除")]),_:1},8,["disabled"])),[[y,"report:categoryRecord:remove"]]),b((n(),s(g,{type:"primary",onClick:o},{default:r(()=>[h("新增")]),_:1})),[[y,"report:categoryRecord:add"]])]),bodyCell:r(({column:_,record:R})=>[_.key==="action"?(n(),s(e($),{key:0,stopButtonPropagation:"",actions:[{label:"修改",icon:e(v).EDIT,type:"primary",ghost:!0,auth:"report:categoryRecord:edit",onClick:a.bind(null,R)},{label:"删除",icon:e(v).DELETE,type:"primary",danger:!0,ghost:!0,auth:"report:categoryRecord:remove",popConfirm:{placement:"left",title:"是否删除分类别评估记录["+R.id+"]?",confirm:i.bind(null,R)}}]},null,8,["actions"])):G("",!0)]),_:1},8,["onRegister"]),w(N,{onRegister:e(f),onReload:e(t)},null,8,["onRegister","onReload"])]),_:1})}}});export{ce as default};