ui: show project names in IAMUserList instead of count
Display project name tags (green=monitoring, grey=not) with a 'manage' link to the policy page. Much more informative at a glance. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
parent
9e81717e08
commit
236e082349
@ -51,11 +51,17 @@
|
||||
<span v-else style="color:#999;font-size:12px;">未划拨</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="项目" min-width="80" align="center">
|
||||
<el-table-column label="关联项目" min-width="180">
|
||||
<template #default="{ row }">
|
||||
<el-button link type="primary" size="small" @click="$router.push(`/iam-users/${row.id}/policies`)">
|
||||
{{ row.monitored_project_count || 0 }} / {{ (row.projects || []).length }}
|
||||
</el-button>
|
||||
<div style="display:flex; flex-wrap:wrap; gap:4px; align-items:center;">
|
||||
<el-tag v-for="p in (row.projects || [])" :key="p.project_name"
|
||||
:type="p.monitor_enabled ? 'success' : 'info'" size="small">
|
||||
{{ p.project_name }}
|
||||
</el-tag>
|
||||
<el-button link type="primary" size="small" @click="$router.push(`/iam-users/${row.id}/policies`)"
|
||||
style="font-size:12px;">管理</el-button>
|
||||
</div>
|
||||
<span v-if="!(row.projects || []).length" style="color:#999;font-size:12px;">未关联</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column label="告警" min-width="110" align="center">
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user