需求变更
This commit is contained in:
@@ -240,7 +240,7 @@ export default {
|
|||||||
return (
|
return (
|
||||||
(this.tree.store.direction === "horizontal" &&
|
(this.tree.store.direction === "horizontal" &&
|
||||||
this.showCollapsable &&
|
this.showCollapsable &&
|
||||||
this.leftChildNodes.length > 0)
|
this.leftChildNodes.length > 0)
|
||||||
)
|
)
|
||||||
},
|
},
|
||||||
// 节点的宽度
|
// 节点的宽度
|
||||||
@@ -356,6 +356,11 @@ export default {
|
|||||||
this.node.collapse();
|
this.node.collapse();
|
||||||
this.tree.$emit("node-collapse", this.node.data, this.node, this);
|
this.tree.$emit("node-collapse", this.node.data, this.node, this);
|
||||||
} else {
|
} else {
|
||||||
|
if (this.node.parent.childNodes && this.node.parent.childNodes.length) {
|
||||||
|
this.node.parent.childNodes.forEach(e => {
|
||||||
|
e.collapse()
|
||||||
|
})
|
||||||
|
}
|
||||||
this.node.expand();
|
this.node.expand();
|
||||||
this.tree.$emit("node-expand", this.node.data, this.node, this);
|
this.tree.$emit("node-expand", this.node.data, this.node, this);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user