Просмотр исходного кода

修复仓库删除细节问题

shaogen1995 4 лет назад
Родитель
Сommit
5d64681e52
1 измененных файлов с 12 добавлено и 0 удалено
  1. 12 0
      src/views/statistics/statistics0.vue

+ 12 - 0
src/views/statistics/statistics0.vue

@@ -259,6 +259,8 @@ export default {
         // console.log(666, this.allList[this.arrowsShow].children[this.entrepotShow].id)
         remove(this.allList[this.arrowsShow].children[this.entrepotShow].id)
         this.entrepotShow = 0
+        this.arrowsShow = null
+        this.towList.name = ''
         this.$nextTick(() => {
           setTimeout(() => {
             this.getTreeList()
@@ -310,6 +312,15 @@ export default {
       this.getTreeList()
       this.myId = null
       this.$message.success('仓库操作成功')
+      this.$nextTick(() => {
+        setTimeout(() => {
+          // console.log(999, (this.allList[this.arrowsShow].children).length - 1)
+          // console.log(999, this.allList[this.arrowsShow].children)
+          this.entrepotShow = (this.allList[this.arrowsShow].children).length - 1
+          this.towList = this.allList[this.arrowsShow].children[(this.allList[this.arrowsShow].children).length - 1]
+          // console.log(999, this.towList)
+        }, 100)
+      })
     },
     // 点击第三层
     delThree (id) {
@@ -390,6 +401,7 @@ export default {
     },
     // 点击第二层
     entrepotShowClick (ind, val) {
+      // console.log(9999999, ind, val)
       this.entrepotShow = ind
       this.towList = val
       // console.log(666, val)