From 00468a057ca642bc535dfdf80c7c1c7716eea4f0 Mon Sep 17 00:00:00 2001
From: shuishen <1109946754@qq.com>
Date: Wed, 27 Nov 2024 19:32:14 +0800
Subject: [PATCH] 地图销毁相关处理

---
 src/views/companyInfo/index.vue |    6 +++---
 1 files changed, 3 insertions(+), 3 deletions(-)

diff --git a/src/views/companyInfo/index.vue b/src/views/companyInfo/index.vue
index e20319f..b2a537b 100644
--- a/src/views/companyInfo/index.vue
+++ b/src/views/companyInfo/index.vue
@@ -2,7 +2,7 @@
  * @Author: shuishen 1109946754@qq.com
  * @Date: 2024-11-08 11:00:30
  * @LastEditors: shuishen 1109946754@qq.com
- * @LastEditTime: 2024-11-25 16:45:39
+ * @LastEditTime: 2024-11-27 19:16:37
  * @FilePath: \bigScreen\src\views\companyInfo\index.vue
  * @Description:
  *
@@ -41,11 +41,11 @@
 curCompanyWall.addOverlay(wall)
 
 onMounted(() => {
-  window.$viewer.flyTo(curCompanyWall)
+  window.$viewer && window.$viewer.flyTo(curCompanyWall)
 })
 
 onUnmounted(() => {
-  window.$viewer.removeLayer(curCompanyWall)
+  window.$viewer && window.$viewer.removeLayer(curCompanyWall)
 })
 
 const handleChildEvent = (data) => {

--
Gitblit v1.9.3