first commit
This commit is contained in:
@@ -0,0 +1 @@
|
||||
import{j as a,B as i,x as n}from"./index-B-sDl1ER.js";import{X as d}from"./index-rMui37zI.js";import{T as s}from"./index-C9m5qSM4.js";import"./index-duCmqVUU.js";import"./index-CO5DzGxy.js";import"./index-BZjcF0yn.js";import"./tslib.es6-BaFViOhq.js";import"./index-D3yl9SWR.js";import"./progress-C__thZ4V.js";import"./Table-B11dzOaz.js";import"./index-CeRfFUxJ.js";import"./index-DmtjhyJb.js";import"./index-CkiGQ3z2.js";import"./index-Bc7ikhKh.js";const m=Array.from({length:50},(l,t)=>({id:t+1,name:`用户${t+1}`,email:`user${t+1}@example.com`,age:Math.floor(Math.random()*40)+20,status:Math.random()>.3?1:0,role:["管理员","编辑","访客"][Math.floor(Math.random()*3)],department:["技术部","产品部","运营部","市场部"][Math.floor(Math.random()*4)],createdAt:new Date(Date.now()-Math.random()*1e10).toLocaleDateString()})),j=()=>{const l=[{title:"序号",width:60,valueType:"text",dataIndex:"id"},{dataIndex:"name",title:"用户名",width:120,valueType:"text",required:!0},{dataIndex:"email",title:"邮箱",valueType:"text",width:200,ellipsis:!0},{dataIndex:"age",title:"年龄",width:80,valueType:"digit",sorter:(e,o)=>e.age-o.age,hideInSearch:!0},{dataIndex:"status",title:"状态",width:100,valueType:"select",render:e=>{const r={1:{text:"启用",color:"green"},0:{text:"禁用",color:"red"}}[e];return r?a.jsx(s,{color:r.color,children:r.text}):"-"},filters:[{text:"启用",value:1},{text:"禁用",value:0}]},{dataIndex:"role",title:"角色",width:100,valueType:"select",fieldProps:{options:[{label:"管理员",value:"管理员"},{label:"编辑",value:"编辑"},{label:"访客",value:"访客"}]}},{dataIndex:"department",title:"部门",width:120,valueType:"select",fieldProps:{options:[{label:"技术部",value:"技术部"},{label:"产品部",value:"产品部"},{label:"运营部",value:"运营部"},{label:"市场部",value:"市场部"}]},hideInSearch:!0},{dataIndex:"createdAt",title:"创建时间",width:120,hideInForm:!0,hideInSearch:!0}],t=e=>[a.jsx(i,{icon:a.jsx(n,{}),children:"导出"},"export"),e.columnSetting,e.hideBorder,e.reload,e.columnHeight];return a.jsx(d,{columns:l,rowKey:"id",dataSource:m,accessName:"system.user.list",api:"/system-user/list",toolBarRender:t})};export{j as default};
|
||||
Reference in New Issue
Block a user