当前位置:网站首页>El tree whether leaf node or not, the drop-down button is permanent
El tree whether leaf node or not, the drop-down button is permanent
2022-07-05 02:46:00 【AzeShinja】
After looking around, I didn't configure the permanent drop-down button , Then we will change his properties
My tree sub nodes are obtained by clicking a folder and requesting the interface , So we used updateKeyChildren This function
So let's encapsulate this function
updateKeyChildren(id, data) {
this.$refs.projectTree.updateKeyChildren(id, data);
const node = this.$refs.projectTree.getNode(id);
node.childNodes.forEach((item) => {
item.expanded = false;
item.isLeaf = false;
});
},
That's it , After testing getNode And traverse this childNodes It takes little time to use .
If there is a better way to leave a message in the comment area
边栏推荐
- openresty ngx_lua执行阶段
- 【LeetCode】501. Mode in binary search tree (2 wrong questions)
- Master Fur
- Simple use of devtools
- Eight days of learning C language - while loop (embedded) (single chip microcomputer)
- Talk about the things that must be paid attention to when interviewing programmers
- Linux安装Redis
- spoon插入更新oracle数据库,插了一部分提示报错Assertion botch: negative time
- Cut! 39 year old Ali P9, saved 150million
- Port, domain name, protocol.
猜你喜欢

Bumblebee: build, deliver, and run ebpf programs smoothly like silk

Design and implementation of community hospital information system

Idea inheritance relationship

【LeetCode】98. Verify the binary search tree (2 brushes of wrong questions)

Pytest (5) - assertion

Design of KTV intelligent dimming system based on MCU

this+闭包+作用域 面试题

Flume配置4——自定义MYSQLSource

This + closure + scope interview question

The most powerful new household god card of Bank of communications. Apply to earn 2100 yuan. Hurry up if you haven't applied!
随机推荐
使用druid連接MySQL數據庫報類型錯誤
单项框 复选框
Pytest (4) - test case execution sequence
Moco V2 literature research [self supervised learning]
ASP. Net core 6 framework unveiling example demonstration [01]: initial programming experience
【微服务|SCG】Filters的33种用法
The perfect car for successful people: BMW X7! Superior performance, excellent comfort and safety
【LeetCode】501. Mode in binary search tree (2 wrong questions)
February database ranking: how long can Oracle remain the first?
LeetCode 314. Binary tree vertical order traversal - Binary Tree Series Question 6
College Students' innovation project management system
Introduce reflow & repaint, and how to optimize it?
Elk log analysis system
打破信息茧房-我主动获取信息的方法 -#3
Spark SQL learning bullet 2
ASP. Net core 6 framework unveiling example demonstration [01]: initial programming experience
tuple and point
Why are there fewer and fewer good products produced by big Internet companies such as Tencent and Alibaba?
Use the difference between "Chmod a + X" and "Chmod 755" [closed] - difference between using "Chmod a + X" and "Chmod 755" [closed]
2.常见的请求方法