Kaynağa Gözat

首页 大屏统计 banner bugfix

kevin_zhangl 3 yıl önce
ebeveyn
işleme
f4a799f4b1
1 değiştirilmiş dosya ile 5 ekleme ve 3 silme
  1. 5 3
      frontendEle/src/views/dashboard/index.vue

+ 5 - 3
frontendEle/src/views/dashboard/index.vue

@@ -145,9 +145,11 @@
       },
       imgLoad() {
         let _this = this
-        _this.$nextTick(function () {
-          _this.bannerHeight = _this.$refs.bannerHeight[0].height
-        })
+        if (_this.$refs.bannerHeight) {
+          _this.$nextTick(function () {
+            _this.bannerHeight = _this.$refs.bannerHeight[0].height
+          })
+        }
       }
     }
   }