Browse Source

根据不同登录账号显示不同地图(所有2.5D地图)

彭宇 2 years ago
parent
commit
173609c712
3 changed files with 27 additions and 23 deletions
  1. 3 2
      src/views/datacenter.vue
  2. 13 11
      src/views/forest.vue
  3. 11 10
      src/views/monitor.vue

+ 3 - 2
src/views/datacenter.vue

@@ -153,8 +153,9 @@ export default {
   mounted() {
     // 初始化地图数据
     this.getSuperMapUrl();
-
-    this.getResource();
+    setTimeout(() => {
+      this.getResource();
+    }, 2000)
     this.bottomMenuList(); //获取底部公共组件消息和任务
   },
   data() {

+ 13 - 11
src/views/forest.vue

@@ -509,18 +509,20 @@
       // 初始化地图数据
       this.getSuperMapUrl();
 
-      this.getBaseInfo()
-      this.getTodayEvents(this.getCurrentDataStr())
-      this.getDeptEventCount(this.getCurrentDataStr())
-      this.getWeather(this.getCurrentDataStr())
-      this.getEventList(this.getCurrentDataStr(), this.pageSize, this.pageNum)
-      this.getEventByEventType(this.getCurrentDataStr())
-      this.getEventByReportorOrder(this.getCurrentDataStr())
-      this.getExposureStage(this.getCurrentDataStr())
-      this.getSupermap(this.getCurrentDataStr())
-      this.getMenuEventType()
+      setTimeout(() => {
+        this.getBaseInfo()
+        this.getTodayEvents(this.getCurrentDataStr())
+        this.getDeptEventCount(this.getCurrentDataStr())
+        this.getWeather(this.getCurrentDataStr())
+        this.getEventList(this.getCurrentDataStr(), this.pageSize, this.pageNum)
+        this.getEventByEventType(this.getCurrentDataStr())
+        this.getEventByReportorOrder(this.getCurrentDataStr())
+        this.getExposureStage(this.getCurrentDataStr())
+        this.getSupermap(this.getCurrentDataStr())
+        this.getMenuEventType()
+        this.getResource()
+      }, 2000)
 
-      this.getResource()
       /** ----------------------------------weosocket开始------------------------------------- */
       // this.initWebSocket()
       /** ----------------------------------weosocket结束------------------------------------- */

+ 11 - 10
src/views/monitor.vue

@@ -198,16 +198,17 @@
     mounted() {
       // 初始化地图数据
       this.getSuperMapUrl();
-
-      this.selectKeyAreaList()
-      this.bottomMenuList() //获取底部公共组件消息和任务
-      this.getTreeselect()
-      this.deptId = Cookies.get("deptId")
-      // this.chuanSet()
-      this.getMonitorDeviceAndDataLists()
-      // this.getDlblistBydeptIds()
-      this.selectDeviceType(-1)
-      // this.showTVWall();
+      setTimeout(() => {
+        this.selectKeyAreaList()
+        this.bottomMenuList() //获取底部公共组件消息和任务
+        this.getTreeselect()
+        this.deptId = Cookies.get("deptId")
+        // this.chuanSet()
+        this.getMonitorDeviceAndDataLists()
+        // this.getDlblistBydeptIds()
+        this.selectDeviceType(-1)
+        // this.showTVWall();
+      }, 2000)
     },
     data() {
       return {