2 lines
4.3 KiB
JavaScript
2 lines
4.3 KiB
JavaScript
|
import{d as V,f as z,O as F,n as R,r as T,h as c,c as g,e as a,w as s,a as d,t as m,u as l,N as n,i as u,y as U,I as j,R as B,W as I,X as L,cK as Y,E as $,Y as H,$ as M,ah as S,aj as q,at as K,a0 as O}from"./index-4dcc0234.js";/* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css *//* empty css */import"./el-tooltip-4ed993c7.js";/* empty css *//* empty css *//* empty css *//* empty css */import"./el-form-item-4ed993c7.js";import{_ as W}from"./member_head-a897263d.js";import{y as X}from"./site-ac963391.js";const A={class:"main-container"},G={class:"flex justify-between items-center"},J={class:"text-[20px]"},Q={class:"w-[35px] h-[35px] flex items-center justify-center"},Z=["src"],ee={key:1,src:W,class:"w-[35px] rounded-full"},te={class:"mt-[16px] flex justify-end"},Ce=V({__name:"user",setup(ae){const v=z(),w=F().meta.title,e=R({page:1,limit:10,total:0,loading:!0,data:[],searchParam:{username:"",site_name:"",last_time:[]}}),h=T(),x=r=>{r&&(r.resetFields(),p())},p=(r=1)=>{e.loading=!0,e.page=r,X({page:e.page,limit:e.limit,...e.searchParam}).then(o=>{e.loading=!1,e.data=o.data.data,e.total=o.data.total}).catch(()=>{e.loading=!1})};p();const y=r=>{v.push({path:"/admin/site/user_info",query:{uid:r}})};return(r,o)=>{const k=I,_=L,C=Y,f=$,E=H,b=M,i=S,P=q,N=K,D=O;return c(),g("div",A,[a(b,{class:"box-card !border-none",shadow:"never"},{default:s(()=>[d("div",G,[d("span",J,m(l(w)),1)]),a(b,{class:"box-card !border-none my-[10px] table-search-wrap",shadow:"never"},{default:s(()=>[a(E,{inline:!0,model:e.searchParam,ref_key:"searchFormRef",ref:h},{default:s(()=>[a(_,{label:l(n)("userName"),prop:"username"},{default:s(()=>[a(k,{modelValue:e.searchParam.username,"onUpdate:modelValue":o[0]||(o[0]=t=>e.searchParam.username=t),placeholder:l(n)("userNamePlaceholder")},null,8,["modelValue","placeholder"])]),_:1},8,["label"]),a(_,{label:l(n)("loginTime"),prop:"last_time"},{default:s(()=>[a(C,{modelValue:e.searchParam.last_time,"onUpdate:modelValue":o[1]||(o[1]=t=>e.searchParam.last_time=t),type:"datetimerange","value-format":"YYYY-MM-DD HH:mm:ss","start-placeholder":l(n)("startDate"),"end-placeholder":l(n)("endDate")},null,8,["modelValue","start-placeholder","end-placeholder"])]),_:1},8,["label"]),a(_,null,{default:s(()=>[a(f,{type:"primary",onClick:o[2]||(o[2]=t=>p())},{default:s(()=>[u(m(l(n)("search")),1)]),_:1}),a(f,{onClick:o[3]||(o[3]=t=>x(h.value))},{default:s(()=>[u(m(l(n)("reset")),1)]),_:1})]),_:1})]),_:1},8,["model"])]),_:1}),d("div",null,[U((c(),j(P,{data:e.data,size:"large"},{empty:s(()=>[d("span",null,m(e.loading?"":l(n)("emptyData")),1)]),default:s(()=>[a(i,{label:l(n)("headImg"),width:"100",align:"left"},{default:s(({row:t})=>[d("div",Q,[t.head_img?(c(),g("img",{key:0,src:l(B)(t.head_img),class:"w-[35px] rounded-full"},null,8,Z)):(c(),g("img",ee))])]),_:1},8,["label"]),a(i,{prop:"username",label:l(n)("accountNumber"),"min-width":"120","show-overflow-tooltip":""},null,8,["label"]),a(i,{prop:"real_name",label:l(n)("userRealName"),"min-width":"120","show-overflow-tooltip":""},null,8,["label"]),a(i,{prop:"site_num",label:l(n)("siteNum"),"min-width":"120","show-overflow-tooltip":"",align:"center"},null,8,["label"]),a(i,{prop:"last_time",label:l(n)("lastLoginTime"),"min-width":"180",align:"center"},{default:s(({row:t})=>[u(m(t.last_time||""),1)]),_:1},8,["label"]),a(i,{label:l(n)("lastLoginIP"),"min-width":"180",align:"center"},{default:s(({row:t})=>[u(m(t.last_ip||""),1)]),_:1},8,["label"]),a(i,{label:l(n)("operation"),align:"right",fixed:"right",width:"160"},{default:s(({row:t})=>[a(f,{type:"primary",link:"",onClick:oe=>y(t.uid)},{default:s(()=>[u(m(l(n)("detail")),1)]),_:2},1032,["onClick"])]),_:1},8,["label"])]),_:1},8,["data"])),[[D,e.loading]]),d("div",te,[a(N,{"current-page":e.page,"onUpdate:current-p
|