需求变更

This commit is contained in:
yanran200730
2022-08-01 17:45:20 +08:00
parent 875301eb1d
commit a1c0de83f0

View File

@@ -240,7 +240,7 @@ export default {
return (
(this.tree.store.direction === "horizontal" &&
this.showCollapsable &&
this.leftChildNodes.length > 0)
this.leftChildNodes.length > 0)
)
},
// 节点的宽度
@@ -356,6 +356,11 @@ export default {
this.node.collapse();
this.tree.$emit("node-collapse", this.node.data, this.node, this);
} else {
if (this.node.parent.childNodes && this.node.parent.childNodes.length) {
this.node.parent.childNodes.forEach(e => {
e.collapse()
})
}
this.node.expand();
this.tree.$emit("node-expand", this.node.data, this.node, this);
}