소스 검색

首页 大屏统计 banner bugfix

kevin_zhangl 3 년 전
부모
커밋
f4a799f4b1
1개의 변경된 파일5개의 추가작업 그리고 3개의 파일을 삭제
  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
+          })
+        }
       }
     }
   }