Przeglądaj źródła

数据阈值修改

wwh 2 lat temu
rodzic
commit
cb066e1928

+ 6 - 6
huimv-admin/src/main/java/com/huimv/admin/service/impl/ProtThresholdServiceImpl.java

@@ -137,17 +137,17 @@ public class ProtThresholdServiceImpl extends ServiceImpl<ProtThresholdMapper, P
                 protThreshold1.setDataType(protThreshold.getDataType());
 
 
-                if (Integer.parseInt(protThreshold.getCod2()) < Integer.parseInt(protThreshold.getCod1())) {
+                if (Integer.parseInt(protThreshold.getCod2()) <= Integer.parseInt(protThreshold.getCod1())) {
                     return new Result(ResultCode.FAIL, "红色预警浓度不能低于橙色预警浓度");
-                } else if (Integer.parseInt(protThreshold.getPh2()) < Integer.parseInt(protThreshold.getPh1())) {
+                } else if (Integer.parseInt(protThreshold.getPh2()) <= Integer.parseInt(protThreshold.getPh1())) {
                     return new Result(ResultCode.FAIL, "红色预警浓度不能低于橙色预警浓度");
-                } else if (Integer.parseInt(protThreshold.getNh3n2()) < Integer.parseInt(protThreshold.getNh3n1())) {
+                } else if (Integer.parseInt(protThreshold.getNh3n2()) <= Integer.parseInt(protThreshold.getNh3n1())) {
                     return new Result(ResultCode.FAIL, "红色预警浓度不能低于橙色预警浓度");
-                } else if (Integer.parseInt(protThreshold.getTp2()) < Integer.parseInt(protThreshold.getTp1())) {
+                } else if (Integer.parseInt(protThreshold.getTp2()) <= Integer.parseInt(protThreshold.getTp1())) {
                     return new Result(ResultCode.FAIL, "红色预警浓度不能低于橙色预警浓度");
-                } else if (Integer.parseInt(protThreshold.getTn2()) < Integer.parseInt(protThreshold.getTn1())) {
+                } else if (Integer.parseInt(protThreshold.getTn2()) <= Integer.parseInt(protThreshold.getTn1())) {
                     return new Result(ResultCode.FAIL, "红色预警浓度不能低于橙色预警浓度");
-                } else if (Integer.parseInt(protThreshold.getFlow2()) < Integer.parseInt(protThreshold.getFlow1())) {
+                } else if (Integer.parseInt(protThreshold.getFlow2()) <= Integer.parseInt(protThreshold.getFlow1())) {
                     return new Result(ResultCode.FAIL, "红色预警浓度不能低于橙色预警浓度");
                 } else {