当前位置:网站首页>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
边栏推荐
- Elfk deployment
- When to catch an exception and when to throw an exception- When to catch the Exception vs When to throw the Exceptions?
- qrcode:将文本生成二维码
- ASP. Net core 6 framework unveiling example demonstration [01]: initial programming experience
- 数据库和充值都没有了
- D3js notes
- 【LeetCode】404. Sum of left leaves (2 brushes of wrong questions)
- ELK日志分析系统
- From task Run get return value - getting return value from task Run
- 低度酒赛道进入洗牌期,新品牌如何破局三大难题?
猜你喜欢
Asp+access campus network goods trading platform
Apache Web page security optimization
College Students' innovation project management system
Can you really learn 3DMAX modeling by self-study?
Naacl 2021 | contrastive learning sweeping text clustering task
This + closure + scope interview question
Hmi-31- [motion mode] solve the problem of picture display of music module
问题解决:AttributeError: ‘NoneType‘ object has no attribute ‘append‘
this+闭包+作用域 面试题
Elk log analysis system
随机推荐
Can you really learn 3DMAX modeling by self-study?
Flume配置4——自定义MYSQLSource
Yolov5 model training and detection
D3js notes
Application and Optimization Practice of redis in vivo push platform
为什么腾讯阿里等互联网大厂诞生的好产品越来越少?
Last words record
打破信息茧房-我主动获取信息的方法 -#3
【LeetCode】222. The number of nodes of a complete binary tree (2 mistakes)
spoon插入更新oracle数据库,插了一部分提示报错Assertion botch: negative time
Comparison of advantages and disadvantages between platform entry and independent deployment
Pytorch register_ Hook (operate on gradient grad)
Marubeni Baidu applet detailed configuration tutorial, approved.
Design and implementation of high availability website architecture
How to make OS X read bash_ Profile instead of Profile file - how to make OS X to read bash_ profile not . profile file
【LeetCode】501. Mode in binary search tree (2 wrong questions)
How to find hot projects in 2022? Dena community project progress follow-up, there is always a dish for you (1)
[Yu Yue education] National Open University spring 2019 0505-22t basic nursing reference questions
Apache build web host
Single line function*