[代码优化](v2.6):角色管理选择菜单Bug修复

This commit is contained in:
ZhengJie
2020-11-16 18:28:13 +08:00
parent 3f51dc143e
commit 4e5520ba25

View File

@@ -240,9 +240,12 @@ export default {
} }
} else { } else {
for (let i = 0; i < childIds.length; i++) { for (let i = 0; i < childIds.length; i++) {
const index = this.menuIds.indexOf(childIds[i])
if (index === -1) {
this.menuIds.push(childIds[i]) this.menuIds.push(childIds[i])
} }
} }
}
this.$refs.menu.setCheckedKeys(this.menuIds) this.$refs.menu.setCheckedKeys(this.menuIds)
}) })
}, },