Selaa lähdekoodia

修改测风塔下面图表X轴数据

baiyanting 1 vuosi sitten
vanhempi
commit
205eb4216d

+ 2 - 2
src/views/stateMonitor/factoryMonitor/windPowerPlant/windPower/components/windEchart.vue

@@ -198,10 +198,10 @@ export default {
       // 当日0点时间
       var timeStamp = [];
       let stamp = new Date(new Date().setHours(0, 0, 0, 0)).getTime();
-      for (let i = 0; i < 48; i++) {
+      for (let i = 0; i < 24; i++) {
         timeStamp.push(dayjs(stamp).format("MM-DD HH:mm"));
         this.emptyData.push("0");
-        stamp = parseInt(stamp) + 30 * 60 * 1000;
+        stamp = parseInt(stamp) + 60 * 60 * 1000;
       }
       timeStamp.push(dayjs(stamp).format("MM-DD") + "\xa0" + "24:00");
       this.emptyData.push("0");