diff --git a/src/views/trainingPlatform/demonList.vue b/src/views/trainingPlatform/demonList.vue index faadefe7e..ef518c5f6 100644 --- a/src/views/trainingPlatform/demonList.vue +++ b/src/views/trainingPlatform/demonList.vue @@ -155,7 +155,7 @@ export default { }, forTree(item) { item.children && item.children.forEach(childrenItem => { - childrenItem.key = childrenItem.id + childrenItem.type; + childrenItem.key = item.id + childrenItem.id + childrenItem.type; if (childrenItem.children && childrenItem.children.length) { this.forTree(childrenItem); } @@ -207,13 +207,13 @@ export default { }); }, nodeExpand(obj, node, ele) { - const key = obj.id + obj.type; + const key = obj.key; this.expandList = this.expandList.filter(item => item !== key); this.expandList.push(key); localStore.set('trainIngPlatformExpandList' + this.filterSelect + this.userId + this.project, this.expandList); }, nodeCollapse(obj, node, ele) { - const key = obj.id + obj.type; + const key = obj.key; this.expandList = this.expandList.filter(item => item !== key); localStore.set('trainIngPlatformExpandList' + this.filterSelect + this.userId + this.project, this.expandList); },