Update Local Permission Assignments

This commit is contained in:
2026-02-03 18:48:25 +08:00
parent 86b3e4402c
commit 47e1411390
13 changed files with 94 additions and 147 deletions

View File

@@ -38,6 +38,7 @@ export function UserTable({ users, isLoading, onEdit, onDelete }: UserTableProps
<th className="px-4 py-3 font-medium"></th>
<th className="px-4 py-3 font-medium"></th>
<th className="px-4 py-3 font-medium"></th>
<th className="px-4 py-3 font-medium"></th>
<th className="px-4 py-3 font-medium"></th>
<th className="px-4 py-3 font-medium text-right"></th>
</tr>
@@ -58,6 +59,11 @@ export function UserTable({ users, isLoading, onEdit, onDelete }: UserTableProps
{user.is_superuser ? '超级管理员' : '普通用户'}
</Badge>
</td>
<td className="px-4 py-3">
{(user.is_superuser || user.can_use_local_model) && (
<Badge variant="secondary"></Badge>
)}
</td>
<td className="px-4 py-3">
{new Date(user.created_at).toLocaleString('zh-CN')}
</td>
@@ -129,6 +135,14 @@ export function UserTable({ users, isLoading, onEdit, onDelete }: UserTableProps
{user.is_superuser ? '超级管理员' : '普通用户'}
</Badge>
</div>
<div className="flex justify-between items-center">
<span className="text-muted-foreground">:</span>
{(user.is_superuser || user.can_use_local_model) ? (
<Badge variant="secondary"></Badge>
) : (
<span className="text-xs text-muted-foreground"></span>
)}
</div>
<div className="flex justify-between">
<span className="text-muted-foreground">:</span>
<span className="text-xs">{new Date(user.created_at).toLocaleString('zh-CN')}</span>