var b=Object.defineProperty,k=Object.defineProperties;var I=Object.getOwnPropertyDescriptors;var m=Object.getOwnPropertySymbols;var y=Object.prototype.hasOwnProperty,C=Object.prototype.propertyIsEnumerable;var a=(t,e,o)=>e in t?b(t,e,{enumerable:!0,configurable:!0,writable:!0,value:o}):t[e]=o,p=(t,e)=>{for(var o in e||(e={}))y.call(e,o)&&a(t,o,e[o]);if(m)for(var o of m(e))C.call(e,o)&&a(t,o,e[o]);return t},l=(t,e)=>k(t,I(e));import{d as u,a2 as R,ad as S,af as L,k as T,u as i}from"./vue-vendor-CxLCUzY4.js";import"./index-LwlFn7Y4.js";import{render as c}from"./renderUtils-Cbe4E0PZ.js";import{b3 as v,h as d,u as K}from"./index-B_2CoVdl.js";import{useListPage as M}from"./useListPage-BEtybUiF.js";import{Q as P}from"./componentMap-CzCGDP7x.js";import B from"./BasicTable-Clbg3fHx.js";import"./antd-vue-vendor-CDWW6V_M.js";import"./index-CkL00Q0a.js";import"./vxe-table-vendor-B5h3MVdD.js";import"./index-ARbUvvsq.js";import"./useForm-CcjrODHR.js";import"./index-DAURrYyA.js";import"./index-D2AmS0aU.js";import"./BasicModal-D3g2CFhF.js";import"./ModalHeader-C-C0dUi_.js";import"./useTimeout-CB9F1PLu.js";import"./useWindowSizeFn-C3WExEpc.js";import"./index-Dz2zbQB_.js";import"./index-exs4VcBw.js";import"./index-ByLO0zSl.js";import"./useIntersectionObserver-FVRzwlSd.js";import"./JAreaLinkage-CSgDAlrn.js";import"./areaDataUtil-DFHnz1wu.js";import"./china-area-data-vendor-D0sJ9kfX.js";import"./JSelectUser-BQIJUcBR.js";import"./props-BCVPj-bG.js";import"./JSelectBiz-CJyWq5s2.js";import"./JSelectDept-wKz_Qtmc.js";import"./index-BKs2x_To.js";import"./bem-C6eT35UB.js";import"./props-BLY2qIO5.js";import"./useContextMenu-CSt5a1-F.js";import"./JCodeEditor-esTLnfS3.js";import"./useFormItem-CWa0w7fA.js";import"./htmlmixed-DRe7JlAp.js";import"./vue-B0b3nX1K.js";/* empty css             */import"./JAddInput-YFlAniYT.js";import"./depart.api-0qTriT9h.js";import"./JPopup-BJBYqoWe.js";import"./EasyCronInput-DclSHT47.js";import"./JEllipsis-Cn7GCKHR.js";import"./JDictSelectTag-CxpDdimB.js";import"./download-2tYEzlDW.js";import"./base64Conver-24EVOS6V.js";import"./index-Cgt544dC.js";import"./index-BZ9ST2iq.js";import"./useCountdown-ImUE7YaG.js";import"./useFormItemSingle-DM34aWgK.js";import"./JUpload-DzM-D4DX.js";import"./index-khU3p_On.js";import"./index-DPEnuI0R.js";import"./index-Cnb8BkwG.js";import"./injectionKey-DPVn4AgL.js";const F=[{title:"用户账号",align:"center",dataIndex:"username",customRender:({text:t,record:e})=>{let o=v();return e.token===o?t+"（我）":t}},{title:"用户姓名",align:"center",dataIndex:"realname"},{title:"头像",align:"center",width:120,dataIndex:"avatar",customRender:c.renderAvatar},{title:"生日",align:"center",dataIndex:"birthday"},{title:"性别",align:"center",dataIndex:"sex",customRender:({text:t})=>c.renderDict(t,"sex")},{title:"手机号",align:"center",dataIndex:"phone"}],X=[{field:"username",label:"用户账号",component:"Input",colProps:{span:6}}];const A=t=>d.get({url:"/sys/online/list",params:t}),D=t=>d.post({url:"/sys/online/forceLogout",params:t},{isTransformResponse:!1}),E=u({name:"online-user"}),jt=u(l(p({},E),{setup(t){const{prefixCls:e,tableContext:o,onImportXls:H,onExportXls:N}=M({designScope:"online-user",tableProps:{rowKey:"token",title:"在线用户",api:A,columns:F,formConfig:{schemas:X},actionColumn:{width:120},rowSelection:null}}),[f,{reload:g},{rowSelection:x,selectedRowKeys:Q}]=o,s=K();function h(r){return[{label:"强退",popConfirm:{title:"强制退出用户？",confirm:_.bind(null,r)}}]}function _(r){D({token:r.token}).then(n=>{n.success?(g(),s.createMessage.success("强制退出用户”"+r.realname+"“成功！")):s.createMessage.warn(n.message)})}return(r,n)=>(R(),S(i(B),{onRegister:i(f),rowSelection:i(x)},{action:L(({record:w})=>[T(i(P),{actions:h(w)},null,8,["actions"])]),_:1},8,["onRegister","rowSelection"]))}}));export{jt as default};
