import{u as m}from"./hooks.f4063c52.js";import{_ as w,q as A,B as z,a4 as D,r as o,o as F,n as I,t,H as n,p as u,v as f,O as R,S as _}from"./index.7a111e62.js";const T={class:"config"},N={class:"p-2"},S=_(" \u7F16\u8F91 "),V=_(" \u5220\u9664 "),B={class:"absolute left-3 flex items-center"},E=_(" \u5220\u9664 "),$=A({__name:"config",props:{drawer:{type:Boolean,default:!1},drawTitle:{default:""},direction:{default:"rtl"}},emits:["handleClose"],setup(c,{emit:g}){const d=z({}),e=D({tableData:[{name:"\u7981\u7528",dataval:"0"},{name:"\u542F\u7528",dataval:"1"}],isAllChecked:!1,isIndeterminate:!1,selectRecords:[],tablePage:{total:0,currentPage:1,pageSize:10}});function v(){e.isAllChecked=!1,e.isIndeterminate=!1,g("handleClose")}function J(l){}function U(l){}const b=()=>{setTimeout(()=>{},1e3);const l=d.value;l.setAllCheckboxRow(e.isAllChecked),e.selectRecords=l.getCheckboxRecords()},p=({records:l})=>{const a=d.value;e.isAllChecked=a.isAllCheckboxChecked(),e.isIndeterminate=a.isAllCheckboxIndeterminate(),e.selectRecords=l};return(l,a)=>{const C=o("el-divider"),i=o("vxe-table-column"),r=o("el-button"),x=o("vxe-table"),h=o("vxe-checkbox"),k=o("vxe-pager"),y=o("el-drawer");return F(),I("div",T,[t(y,{"model-value":c.drawer,title:c.drawTitle,direction:c.direction,"before-close":v,"destroy-on-close":"",size:"680px"},{default:n(()=>[t(C),u("div",N,[t(x,{ref_key:"xTable",ref:d,border:"",data:e.tableData,onCheckboxChange:p,onCheckboxAll:p},{default:n(()=>[t(i,{type:"checkbox",width:"60"}),t(i,{field:"name",title:"\u540D\u79F0"}),t(i,{field:"dataval",title:"\u6570\u636E\u503C"}),t(i,{title:"\u64CD\u4F5C",fixed:"right"},{default:n(({row:s})=>[t(r,{link:"",type:"primary",icon:f(m)("edits"),onClick:P=>void 0},{default:n(()=>[S]),_:2},1032,["icon","onClick"]),t(r,{link:"",type:"primary",icon:f(m)("delete"),onClick:P=>void 0},{default:n(()=>[V]),_:2},1032,["icon","onClick"])]),_:1})]),_:1},8,["data"]),t(k,{perfect:"","current-page":e.tablePage.currentPage,"onUpdate:current-page":a[1]||(a[1]=s=>e.tablePage.currentPage=s),"page-size":e.tablePage.pageSize,"onUpdate:page-size":a[2]||(a[2]=s=>e.tablePage.pageSize=s),total:e.tablePage.total,layouts:["PrevJump","PrevPage","Number","NextPage","NextJump","Sizes","FullJump","Total"]},{left:n(()=>[u("span",B,[t(h,{modelValue:e.isAllChecked,"onUpdate:modelValue":a[0]||(a[0]=s=>e.isAllChecked=s),indeterminate:e.isIndeterminate,onChange:b},null,8,["modelValue","indeterminate"]),u("p",null,"\u5DF2\u9009\u4E2D"+R(e.selectRecords.length)+"\u6761",1),t(r,{link:"",type:"danger",class:"ml-1"},{default:n(()=>[E]),_:1})])]),_:1},8,["current-page","page-size","total"])])]),_:1},8,["model-value","title","direction"])])}}});var O=w($,[["__scopeId","data-v-157e4d04"]]);export{O as default};
