From c2005614bc57bd96986d8966b8b49fb7c992d841 Mon Sep 17 00:00:00 2001 From: RuoYi Date: Thu, 17 Apr 2025 15:08:32 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E8=A7=92=E8=89=B2=E7=A6=81?= =?UTF-8?q?=E7=94=A8=E4=B8=8D=E5=85=81=E8=AE=B8=E5=88=86=E9=85=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/system/user/authRole.vue | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/src/views/system/user/authRole.vue b/src/views/system/user/authRole.vue index 7fcb38d..121b96a 100644 --- a/src/views/system/user/authRole.vue +++ b/src/views/system/user/authRole.vue @@ -23,7 +23,7 @@ {{ (pageNum - 1) * pageSize + scope.$index + 1 }} - + @@ -65,7 +65,9 @@ const form = ref({ /** 单击选中行数据 */ function clickRow(row) { - proxy.$refs["roleRef"].toggleRowSelection(row); + if (checkSelectable(row)) { + proxy.$refs["roleRef"].toggleRowSelection(row); + } }; /** 多选框选中数据 */ @@ -78,6 +80,11 @@ function getRowKey(row) { return row.roleId; }; +// 检查角色状态 +function checkSelectable(row) { + return row.status === "0" ? true : false; +}; + /** 关闭按钮 */ function close() { const obj = { path: "/system/user" };