mirror of
https://gitee.com/baidu/amis.git
synced 2024-12-04 21:08:55 +08:00
修复 Tree 组件节点勾选异常问题 (#2449)
This commit is contained in:
parent
a799703409
commit
f86872695f
@ -290,7 +290,7 @@ export class TreeSelector extends React.Component<
|
|||||||
let child = children.shift();
|
let child = children.shift();
|
||||||
let index = value.indexOf(child);
|
let index = value.indexOf(child);
|
||||||
|
|
||||||
if (child.children) {
|
if (child.children && child.children.length) {
|
||||||
children.push.apply(children, child.children);
|
children.push.apply(children, child.children);
|
||||||
} else if (!~index && child.value !== 'undefined') {
|
} else if (!~index && child.value !== 'undefined') {
|
||||||
value.push(child);
|
value.push(child);
|
||||||
|
Loading…
Reference in New Issue
Block a user