소스 검색

* 优化弹窗展示
+ 地图桩孔状态更新策略

chen.cheng 3 달 전
부모
커밋
1f1603a0df
2개의 변경된 파일9개의 추가작업 그리고 5개의 파일을 삭제
  1. 8 0
      src/views/cons/screen/PileHoleDetail.vue
  2. 1 5
      src/views/cons/screen/index.vue

+ 8 - 0
src/views/cons/screen/PileHoleDetail.vue

@@ -93,6 +93,7 @@ export default {
     return {
       loaded: false,
       realtimeIndex: {},
+      timer: null,
       lineOpt: {
         tooltip: {
           trigger: 'axis',
@@ -154,6 +155,13 @@ export default {
   },
   created() {
     this.showDialog(this.propData)
+    this.timer = setInterval(() => {
+      this.loaded = false
+      this.showDialog(this.propData)
+    }, 1000 * 30)
+  },
+  beforeDestroy() {
+    this.timer && clearInterval(this.timer)
   },
   methods: {
     showDialog(pileHolleInfo) {

+ 1 - 5
src/views/cons/screen/index.vue

@@ -344,7 +344,6 @@ export default {
               {
                 lineColor: '#34495e',
                 lineWidth: 1,
-                polygonFill: codeToStatus.color,
                 polygonOpacity: 0.8
               }
             ])
@@ -354,7 +353,6 @@ export default {
             {
               lineColor: 'green',
               lineWidth: 1,
-              polygonFill: codeToStatus.color,
               polygonOpacity: 1
             }
           ])
@@ -372,9 +370,7 @@ export default {
                 this.hisClickGeom.updateSymbol([
                   {
                     lineColor: '#34495e',
-                    lineWidth: 1,
-                    polygonFill: codeToStatus.color,
-                    polygonOpacity: 0.8
+                    lineWidth: 1
                   }
                 ])
                 this.hisClickGeom = null