import{d as i,b3 as b,h as w,a$ as v,o as y,c as T,m as e,e as s,p as l,q as E,z as x,aJ as k,A as C,T as B,aW as $}from"./index-XuO881sr.js";import{E as D,a as O}from"./el-table-column-5BM1zXQ-.js";import"./el-checkbox-Cxc7yQYm.js";/* empty css               */import{_ as q}from"./index-DFHXdJnc.js";import{d as z}from"./index-CsWgMqY0.js";const I=i({name:"Online"}),M=i({...I,props:{devices:b.any.isRequired},setup(c){const{proxy:t}=w(),{sys_device_type:p}=v(t?.useDict("sys_device_type")),d=c,_=B(()=>d.devices),m=r=>{$.confirm("删除设备后，在该设备登录需要重新进行验证").then(()=>z(r.tokenId)).then(a=>{a.code===200?(t?.$modal.msgSuccess("删除成功"),t?.$tab.refreshPage()):t?.$modal.msgError(a.msg)}).catch(()=>{})};return(r,a)=>{const u=q,o=O,f=C,g=k,h=D;return y(),T("div",null,[e(h,{data:s(_),border:"",style:{width:"100%",height:"100%","font-size":"14px"}},{default:l(()=>[e(o,{label:"设备类型",align:"center"},{default:l(n=>[e(u,{options:s(p),value:n.row.deviceType},null,8,["options","value"])]),_:1}),e(o,{label:"主机",align:"center",prop:"ipaddr","show-overflow-tooltip":!0}),e(o,{label:"登录地点",align:"center",prop:"loginLocation","show-overflow-tooltip":!0}),e(o,{label:"操作系统",align:"center",prop:"os","show-overflow-tooltip":!0}),e(o,{label:"浏览器",align:"center",prop:"browser","show-overflow-tooltip":!0}),e(o,{label:"登录时间",align:"center",prop:"loginTime",width:"180"},{default:l(n=>[E("span",null,x(s(t).parseTime(n.row.loginTime)),1)]),_:1}),e(o,{label:"操作",align:"center","class-name":"small-padding fixed-width"},{default:l(n=>[e(g,{content:"删除",placement:"top"},{default:l(()=>[e(f,{link:"",type:"primary",icon:"Delete",onClick:N=>m(n.row)},null,8,["onClick"])]),_:2},1024)]),_:1})]),_:1},8,["data"])])}}});export{M as _};
