From 7b84ddd35802d2446e18eb407968f48f3af738fe Mon Sep 17 00:00:00 2001 From: AhJindeg Date: Thu, 4 Apr 2024 18:54:51 +0800 Subject: [PATCH] =?UTF-8?q?perf:=20=F0=9F=8E=88=20add=20await=20for=20next?= =?UTF-8?q?Tick()?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/system/role/RoleDataPermissionForm.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/views/system/role/RoleDataPermissionForm.vue b/src/views/system/role/RoleDataPermissionForm.vue index 0cdc7409..3b8c3ee6 100644 --- a/src/views/system/role/RoleDataPermissionForm.vue +++ b/src/views/system/role/RoleDataPermissionForm.vue @@ -102,8 +102,8 @@ const open = async (row: RoleApi.RoleVO) => { formData.name = row.name formData.code = row.code formData.dataScope = row.dataScope - nextTick((): void => { - row.dataScopeDeptIds?.forEach((deptId: number) => { + await nextTick((): void => { + row.dataScopeDeptIds?.forEach((deptId: number): void => { treeRef.value.setChecked(deptId, true, false) }) })