Sfoglia il codice sorgente

功率不等于0的都做统计

guoqiang 3 mesi fa
parent
commit
aa9a6e55ae

+ 4 - 3
jeecg-module-gather/src/main/java/org/jeecg/modules/fpgJob/LeanModelStatistics.java

@@ -283,8 +283,8 @@ public class LeanModelStatistics {
                         }
                     }
                     // 设备启停统计 end
-                    // 设备停止运行不统计
-                    if (fpgGatherData.getRunCurrent().compareTo(new BigDecimal(systemVariable.getDefaultValue())) < 0) { // 设备停止运行
+                    // 设备功率小于等于0不做统计
+                    if (fpgGatherData.getActivePower().compareTo(BigDecimal.ZERO) <= 0) { // 功率小于等于0
                         // 执行完成数据 标记已处理
                         fpgGatherData.setId(fpgGatherData.getId());
                         fpgGatherDataService.updateById(fpgGatherData);
@@ -476,7 +476,8 @@ public class LeanModelStatistics {
                         return;
                     }
                     // 设备停止运行不统计
-                    if (fpgGatherData.getRunCurrent().compareTo(new BigDecimal(systemVariable.getDefaultValue())) < 0) { // 设备停止运行
+                    if (fpgGatherData.getActivePower().compareTo(BigDecimal.ZERO) <= 0) { // 功率小于等于0
+//                    if (fpgGatherData.getRunCurrent().compareTo(new BigDecimal(systemVariable.getDefaultValue())) < 0) { // 设备停止运行
                         fpgGatherUpdateList.add(fpgGatherData);
                         return;
                     }