guoxiaohuan 4 years ago
parent
commit
063086381b
2 changed files with 9 additions and 3 deletions
  1. 7 2
      src/components/Legend/src/legend.vue
  2. 2 1
      src/components/editLengend.vue

+ 7 - 2
src/components/Legend/src/legend.vue

@@ -316,8 +316,10 @@ export default {
         // 点击展示图例框
         showTl() {
             if (this.showView != 1) {
-                this.setLengedHeight()
                 this.$store.commit('SETSHOWVIEW', 1)
+                setTimeout(() => {
+                    this.setLengedHeight()
+                })
             } else {
                 this.$store.commit('SETSHOWVIEW', 0)
             }
@@ -435,6 +437,9 @@ export default {
                         }
                         this.$store.commit('SETREMARKSTEXT', marks)
                     }
+                    setTimeout(() => {
+                      this.setLengedHeight()  
+                    },);
                 }
                 // let remarksText = ''
                 // this.remarksText = ''
@@ -610,7 +615,7 @@ export default {
             }
             if (window.screen.height > 1000) {
                 dom.style.maxHeight = '768px'
-                this.tableHeigth = '668px'
+                this.tableHeigth = '500px'
             } else {
                 dom.style.maxHeight = '434px'
                 this.tableHeigth = '334px'

+ 2 - 1
src/components/editLengend.vue

@@ -272,7 +272,8 @@ export default {
                     dom2.style.height = tabHeight + 100 + 'px'
                 })
             },
-            deep: true
+            deep: true,
+            immediate:true
         }
     }
 }