Browse Source

feat: 增加 gis目录

zhangys36 2 years ago
parent
commit
86e7800ba0
2 changed files with 15 additions and 10 deletions
  1. 1 0
      package.json
  2. 14 10
      src/views/dashboard-screen/index.vue

+ 1 - 0
package.json

@@ -14,6 +14,7 @@
     "test:ci": "npm run lint && npm run test:unit"
   },
   "dependencies": {
+    "@pattern-x/gemini-viewer-threejs": "^0.2.24",
     "ant-design-vue": "^1.7.8",
     "axios": "0.18.1",
     "core-js": "3.6.5",

+ 14 - 10
src/views/dashboard-screen/index.vue

@@ -1,12 +1,14 @@
 <template>
-  <div class="dashboard-container" v-if="render">
+  <div class="dashboard-container" >
     <div class="header">
       <div class="title clickScoop" @click="openDrawer('数据管理')">
         变电配电大数据可视化系统
       </div>
       <div class="r-title">
         <span @click="$refs.datePicker.open = true" style="cursor: pointer"> {{ dateTitle }}</span>
-        <a-date-picker :showToday="true" :locale="localeZH"
+        <a-date-picker
+                    :show-today="true"
+                    :locale="localeZH"
                        @click="$refs.datePicker.open = false"
                        style="position: absolute;right:20px;top:10px;z-index: -1"
                        ref="datePicker"
@@ -17,11 +19,11 @@
         />
       </div>
     </div>
-    <div class="content-wrap">
+    <div class="content-wrap" v-if="render">
       <div class="coner left">
 
         <div class="o-item map">
-          <ChartMap :openDrawer="openDrawer"/>
+          <ChartMap :open-drawer="openDrawer"/>
           <div class="jryl-wrap">
             <CardWrap>
               <span slot="title" @click="openDrawer('变电-电力异常信息')">今日遗留</span>
@@ -42,7 +44,6 @@
           </CardWrap>
         </div>
 
-
         <div class="o-item b-r-3">
           <div class="t-1">
 
@@ -106,7 +107,7 @@
     <el-drawer
       custom-class="drawer-wrap"
       :title="drawer.title"
-      :destroyOnClose="true"
+      :destroy-on-close="true"
       :visible.sync="drawer.visible"
       :with-header="true"
       size="100%"
@@ -169,10 +170,7 @@ export default {
   created() {
     const doResize = _.debounce(() => {
       console.log('doResize')
-      this.render = false
-      setTimeout(() => {
-        this.render = true
-      }, 100)
+      // this.freshRender()
     }, 500)
     window.addEventListener('resize', doResize)
     window['is'] = this
@@ -206,6 +204,12 @@ export default {
       this.drawer.comp = map[title]
       this.drawer.params = params || {}
       this.drawer = Object.assign({}, this.drawer)
+    },
+    freshRender() {
+      this.render = false
+      setTimeout(() => {
+        this.render = true
+      }, 100)
     }
   }
 }