Procházet zdrojové kódy

大风监测、雨情监测调整

Hwf před 3 měsíci
rodič
revize
5881533e00

+ 3 - 1
src/views/globalMap/RightMenu/DrawTools.vue

@@ -50,7 +50,9 @@
         </div>
       </div>
     </div>
-    <div class="draw-item" :style="{ color: mouseToolState.drawing ? '#ff0000' : '#ffffff' }" @click="openDraw">{{ mouseToolState.drawing ? '关闭绘制' : '开启绘制' }}</div>
+    <div class="draw-item" :style="{ color: mouseToolState.drawing ? '#ff0000' : '#ffffff' }" @click="openDraw">
+      {{ mouseToolState.drawing ? '关闭绘制' : '开启绘制' }}
+    </div>
     <div class="draw-item" @click="handleUndo">撤销</div>
   </div>
 </template>

+ 22 - 21
src/views/globalMap/RightMenu/RainMonitor/index.vue

@@ -205,7 +205,7 @@ import RainRank from '@/views/globalMap/RightMenu/RainMonitor/RainRank.vue';
 import * as XLSX from 'xlsx';
 import { getNextAreaInfo } from '@/api/common';
 import BigNumber from 'bignumber.js';
-import { useDebounce } from '@vueuse/core';
+import { debounce } from '@/utils';
 
 const { proxy } = getCurrentInstance() as ComponentInternalInstance;
 const { district_type } = toRefs<any>(proxy?.useDict('district_type'));
@@ -392,25 +392,29 @@ const handleMouseUp = (event) => {
   mouseStatus.downLeft = 0;
   mouseStatus.left = 0;
 };
-const getRainRange = () => {
-  getRainfallTownNumCount({
-    query: {
-      start_num: rainRange[0],
-      end_num: rainRange[1],
-      timeOption: timeOption.value
-    }
-  }).then((res) => {
-    analyzeData.value = res.rows[0];
-  });
-};
-useDebounce(getRainRange, 1000);
+const getRainRange = debounce(
+  () => {
+    getRainfallTownNumCount({
+      query: {
+        start_num: rainRange[0],
+        end_num: rainRange[1],
+        timeOption: timeOption.value
+      }
+    }).then((res) => {
+      analyzeData.value = res.rows[0];
+    });
+  },
+  1000,
+  false
+);
+getRainRange();
 watch(startLeft, () => {
   getNewRange(0, startLeft.value);
-  useDebounceFn(getRainRange, 1000);
+  getRainRange();
 });
 watch(endLeft, () => {
   getNewRange(1, endLeft.value);
-  useDebounceFn(getRainRange, 1000);
+  getRainRange();
 });
 const getNewRange = (index, value) => {
   if (value >= 0 && value < 192) {
@@ -582,16 +586,12 @@ initData();
   }
   .tr {
     width: 1487px;
-    height: 88px;
+    min-height: 88px;
     background: url('@/assets/images/common/tr.png') no-repeat;
     display: flex;
     align-items: center;
     margin-top: 10px;
-    .td {
-      white-space: nowrap;
-      overflow: hidden;
-      text-overflow: ellipsis;
-    }
+    padding: 22.26px 10px;
   }
   .gradient-text2 {
     color: transparent !important;
@@ -602,6 +602,7 @@ initData();
     display: flex;
     justify-content: center;
     align-items: center;
+    flex: unset;
     &:nth-child(1) {
       width: 140px;
     }

+ 3 - 7
src/views/globalMap/RightMenu/WindMonitor/index.vue

@@ -202,13 +202,11 @@
 </template>
 
 <script setup lang="ts">
-import { onMounted, reactive } from 'vue';
 import { getHelicopterList } from '@/api/globalMap/Helicopter';
 import switchOff from '@/assets/images/map/rightMenu/windMonitor/switch-off.png';
 import switchOn from '@/assets/images/map/rightMenu/windMonitor/switch-on.png';
 import WindSpeedRank from '@/views/globalMap/RightMenu/WindMonitor/windSpeedRank.vue';
 import { getRainfallTownNumCount } from '@/api/globalMap/rainMonitor';
-import { useDebounce } from '@vueuse/core';
 import BigNumber from 'bignumber.js';
 import { debounce } from '@/utils';
 
@@ -612,6 +610,7 @@ onMounted(() => {
   display: flex;
   justify-content: center;
   align-items: center;
+  flex: unset;
   &:nth-child(1) {
     width: 140px;
   }
@@ -619,13 +618,10 @@ onMounted(() => {
     width: 220px;
   }
   &:nth-child(3) {
-    width: 280px;
-  }
-  &:nth-child(4) {
     flex: 1;
   }
-  &:nth-child(5) {
-    width: 230px;
+  &:nth-child(4) {
+    width: 220px;
   }
 }
 .rank1,