fix: role menus

pull/2/head
xingyu4j 2022-12-08 12:36:28 +08:00
parent b46ac885d4
commit c2a3d1240f
1 changed files with 4 additions and 1 deletions

View File

@ -314,7 +314,10 @@ const submitScope = async () => {
} else if ('menu' === actionScopeType.value) { } else if ('menu' === actionScopeType.value) {
const data = ref<PermissionApi.PermissionAssignRoleMenuReqVO>({ const data = ref<PermissionApi.PermissionAssignRoleMenuReqVO>({
roleId: dataScopeForm.id, roleId: dataScopeForm.id,
menuIds: treeRef.value!.getCheckedKeys(false) as unknown as Array<number> menuIds: [
...(treeRef.value!.getCheckedKeys(false) as unknown as Array<number>),
...(treeRef.value!.getHalfCheckedKeys() as unknown as Array<number>)
]
}) })
await PermissionApi.assignRoleMenuApi(data.value) await PermissionApi.assignRoleMenuApi(data.value)
} }