优化登录记录角色展示
将角色从账号列拆出为独立列,避免 Tag 叠在用户名下显示异常。
This commit is contained in:
@@ -85,17 +85,18 @@ export default function AdminDashboardPage() {
|
|||||||
{
|
{
|
||||||
title: '账号',
|
title: '账号',
|
||||||
dataIndex: 'username',
|
dataIndex: 'username',
|
||||||
minWidth: 140,
|
minWidth: 120,
|
||||||
render: (value, row) => (
|
render: (value) => <Typography.Text strong>{value || '-'}</Typography.Text>,
|
||||||
<div className="cell-stack">
|
},
|
||||||
<Typography.Text strong>{value || '-'}</Typography.Text>
|
{
|
||||||
{row.role ? <StatusTag value={row.role} /> : null}
|
title: '角色',
|
||||||
</div>
|
dataIndex: 'role',
|
||||||
),
|
width: 110,
|
||||||
|
render: (value) => <StatusTag value={value} kind="role" />,
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
title: '结果',
|
title: '结果',
|
||||||
width: 100,
|
width: 90,
|
||||||
render: (_, row) =>
|
render: (_, row) =>
|
||||||
row.success ? (
|
row.success ? (
|
||||||
<Tag color="green">成功</Tag>
|
<Tag color="green">成功</Tag>
|
||||||
|
|||||||
Reference in New Issue
Block a user