Merge pull request #291 from 724399396/master

fix tree table get children item bug
This commit is contained in:
Aresn 2020-01-16 08:02:05 +08:00 committed by GitHub
commit 5c86076859
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -842,7 +842,9 @@
break; break;
} else if (thisData.children && thisData.children.length) { } else if (thisData.children && thisData.children.length) {
data = this.getChildrenByRowKey(rowKey, thisData); data = this.getChildrenByRowKey(rowKey, thisData);
if (data && data._rowKey === rowKey) return data; if (data) {
break;
}
} }
} }
return data; return data;
@ -857,6 +859,9 @@
break; break;
} else if (item.children && item.children.length) { } else if (item.children && item.children.length) {
data = this.getChildrenByRowKey(rowKey, item); data = this.getChildrenByRowKey(rowKey, item);
if (data) {
break;
}
} }
} }
} }