fix: disabled node can be checked
修复在 parent node 全选的场景下,被禁用的 child node 也会出现勾选状态的问题
This commit is contained in:
parent
8a994e63bf
commit
2f580dbe32
1 changed files with 5 additions and 1 deletions
|
@ -162,8 +162,12 @@
|
|||
if (this.checkStrictly) return;
|
||||
|
||||
for (let key in changes) {
|
||||
if (key === 'checked' && node.disabled) {
|
||||
this.$set(node, key, node.checked);
|
||||
} else {
|
||||
this.$set(node, key, changes[key]);
|
||||
}
|
||||
}
|
||||
if (node[this.childrenKey]) {
|
||||
node[this.childrenKey].forEach(child => {
|
||||
this.updateTreeDown(child, changes);
|
||||
|
|
Loading…
Add table
Reference in a new issue