From a669adb3e80e58aee84be37d865311717ea61990 Mon Sep 17 00:00:00 2001 From: zhouwx <1175765986@qq.com> Date: 星期四, 14 八月 2025 08:38:37 +0800 Subject: [PATCH] 修改 --- src/views/hazardousChemicals/systemManage/user/index.vue | 7 +++++-- 1 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/views/hazardousChemicals/systemManage/user/index.vue b/src/views/hazardousChemicals/systemManage/user/index.vue index 6908c8a..79afaf4 100644 --- a/src/views/hazardousChemicals/systemManage/user/index.vue +++ b/src/views/hazardousChemicals/systemManage/user/index.vue @@ -40,13 +40,13 @@ </el-table-column> <el-table-column label="用户类型" prop="userType" align="center"> <template #default="scope"> - <span>{{scope.row.userType == 0 ?'管理员':scope.row.userType == 1 ? '企业用户':'普通用户'}}</span> + <span>{{scope.row.userType == 0 ?'管理员':scope.row.userType == 1 ? '企业用户':scope.row.userType ==2 ? '普通用户' : '监管用户'}}</span> </template> </el-table-column> <el-table-column label="操作" align="center" class-name="small-padding fixed-width" > <template #default="scope"> <el-button link type="primary" @click="openDialog('edit',scope.row)">编辑</el-button> - <el-button link type="danger" @click="handleDelete(scope.row)">删除</el-button> + <el-button link type="danger" v-if="!isAdmin" @click="handleDelete(scope.row)">删除</el-button> <el-button link type="primary" @click="openDialog('pwd',scope.row)">修改密码</el-button> </template> </el-table-column> @@ -109,10 +109,13 @@ }); +const isAdmin = ref(false) const { queryParams, total, dataList } = toRefs(data); const userInfo = ref() onMounted(()=>{ userInfo.value = JSON.parse(Cookies.get('userInfo')) + isAdmin.value = userInfo.value.userType === 0; + getList() }) -- Gitblit v1.9.2