This commit is contained in:
Your Name
2026-04-27 15:30:28 +08:00
parent 23bd86e056
commit fe14f67965
21 changed files with 2335 additions and 449 deletions
+17
View File
@@ -21,6 +21,11 @@
show-overflow-tooltip
/>
<el-table-column prop="sort" label="排序" min-width="100" />
<el-table-column label="数据范围" min-width="140">
<template #default="{ row }">
{{ dataScopeLabel(row.data_scope) }}
</template>
</el-table-column>
<el-table-column prop="num" label="管理员人数" min-width="100" />
<el-table-column prop="create_time" label="创建时间" min-width="180" />
<el-table-column label="操作" width="200" fixed="right">
@@ -98,6 +103,18 @@ const handleAuth = async (data: any) => {
authRef.value?.setFormData(data)
}
const dataScopeLabel = (scope: number | string | null | undefined) => {
const s = Number(scope) || 1
return (
({
1: '全部数据(免隔离)',
2: '本部门及下级部门',
3: '仅本部门',
4: '仅本人'
} as Record<number, string>)[s] || '全部数据(免隔离)'
)
}
// 删除角色
const handleDelete = async (id: number) => {
await feedback.confirm('确定要删除?')