适配 `treeTable.expandNode()` 方法

pull/1226/head
贤心 2023-04-21 09:10:14 +08:00
parent 06982a5051
commit 743d5d63af
1 changed files with 4 additions and 1 deletions

View File

@ -1445,7 +1445,10 @@ layui.define(['table'], function (exports) {
var trElem = tableView.find('tr[lay-data-index="' + dataIndex + '"]');
if (!trElem.length) {
// 如果还没有展开没有渲染的要先渲染出来
treeTable.expandNode(id, nodeData[LAY_PARENT_INDEX], true);
treeTable.expandNode(id, {
index: nodeData[LAY_PARENT_INDEX],
expandFlag: true
});
trElem = tableView.find('tr[lay-data-index="' + dataIndex + '"]');
}
checkNode.call(that, trElem, checked, callbackFlag);