浏览代码

Merge branch 'fix_elTree_bug'

jwyu 1 年之前
父节点
当前提交
ce6c298459
共有 2 个文件被更改,包括 11 次插入12 次删除
  1. 7 10
      src/views/dataEntry_manage/databaseList.vue
  2. 4 2
      src/views/predictEdb_manage/mixins/mixin.js

+ 7 - 10
src/views/dataEntry_manage/databaseList.vue

@@ -856,7 +856,7 @@ export default {
 						const {EdbNameEn,EdbName,EdbInfoId,UniqueCode,ClassifyId}=res.Data.Item
 						this.addLabel({code:UniqueCode,id:EdbInfoId,classifyId:ClassifyId,EdbName,EdbNameEn})
 						// 展开目录
-						this.defaultShowNodes=classify_arr.reverse().map(item=>item.UniqueCode)
+						this.defaultShowNodes=classify_arr.map(item=>item.UniqueCode)
 						//设置tree高亮
 						this.$nextTick(()=>{
 							setTimeout(() => {
@@ -1436,7 +1436,10 @@ export default {
 					this.$message.success('移动成功!')
 				}
 				this.getTreeData()
-				this.getDataList();
+				if(this.selected_edbid){
+					this.getDataList();
+				}
+				
 			})
 		},
 
@@ -1458,7 +1461,7 @@ export default {
 				setTimeout(() => {
 					dropLine.style.top=e.layerY+'px'
 					// console.log(e.layerY,dropLine);
-				}, 10);
+				}, 100);
 			}
 			
 		},
@@ -1472,13 +1475,7 @@ export default {
 		// 树节点展开
 		handleNodeExpand (data) {
 			// 保存当前展开的节点
-			let flag = false
-			this.defaultShowNodes.some(item => {
-				if (item === data.UniqueCode) { // 判断当前节点是否存在, 存在不做处理
-					flag = true
-					return true
-				}
-			})
+			let flag = this.defaultShowNodes.some((item) => item === data.UniqueCode);
 			if (!flag) { // 不存在则存到数组里
 				this.defaultShowNodes.push(data.UniqueCode)
 			}

+ 4 - 2
src/views/predictEdb_manage/mixins/mixin.js

@@ -173,7 +173,9 @@ export default {
 					this.$message.success('移动成功!')
 				}
 				this.getTreeData()
-        this.$refs.detailComponentRef.getDetail()
+        if(this.select_id&&!this.showAssociateChart&&!this.showAssociateComputeData){
+          this.$refs.detailComponentRef.getDetail()
+        }
 			})
     },
 
@@ -191,7 +193,7 @@ export default {
 			if(dropLine){
 				setTimeout(() => {
 					dropLine.style.top=e.layerY+'px'
-				}, 10);
+				}, 100);
 			}
     },