Sfoglia il codice sorgente

计算化验记录的偏差度赋值错误的bug修改

王苗苗 6 mesi fa
parent
commit
89ae5d6911

+ 7 - 7
ruoyi-system/src/main/java/com/ruoyi/business/service/impl/BusinessServiceImpl.java

@@ -140,7 +140,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setLowCodResultConcentration(resultConcentration);
                 Double lowCodStandardVal = assayDetailRes.getLowCodStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - lowCodStandardVal) / lowCodStandardVal);
+                assayDetailRes.setLowCodDeviationRate((resultConcentration - lowCodStandardVal) / lowCodStandardVal);
             }
             //氨氮
             Optional<ZAssayResult> andanOptional = zAssayResults.stream().filter(zAssayResult -> "3".equals(zAssayResult.getAssayItem())).findFirst();
@@ -149,7 +149,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setAnDanResultConcentration(resultConcentration);
                 Double anDanStandardVal = assayDetailRes.getAnDanStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - anDanStandardVal) / anDanStandardVal);
+                assayDetailRes.setAnDanDeviationRate((resultConcentration - anDanStandardVal) / anDanStandardVal);
             }
             //总氮
             Optional<ZAssayResult> tnOptional = zAssayResults.stream().filter(zAssayResult -> "4".equals(zAssayResult.getAssayItem())).findFirst();
@@ -158,7 +158,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setTnResultConcentration(resultConcentration);
                 Double tnStandardVal = assayDetailRes.getTnStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - tnStandardVal) / tnStandardVal);
+                assayDetailRes.setTnDeviationRate((resultConcentration - tnStandardVal) / tnStandardVal);
             }
             //总磷
             Optional<ZAssayResult> tpOptional = zAssayResults.stream().filter(zAssayResult -> "5".equals(zAssayResult.getAssayItem())).findFirst();
@@ -167,7 +167,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setTpResultConcentration(resultConcentration);
                 Double tpStandardVal = assayDetailRes.getTpStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - tpStandardVal) / tpStandardVal);
+                assayDetailRes.setTpDeviationRate((resultConcentration - tpStandardVal) / tpStandardVal);
             }
             //正磷酸盐
             Optional<ZAssayResult> zlsyOptional = zAssayResults.stream().filter(zAssayResult -> "6".equals(zAssayResult.getAssayItem())).findFirst();
@@ -176,7 +176,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setZlsyResultConcentration(resultConcentration);
                 Double zlsyStandardVal = assayDetailRes.getZlsyStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - zlsyStandardVal) / zlsyStandardVal);
+                assayDetailRes.setZlsyDeviationRate((resultConcentration - zlsyStandardVal) / zlsyStandardVal);
             }
             //亚硝酸盐氮
             Optional<ZAssayResult> yxsydOptional = zAssayResults.stream().filter(zAssayResult -> "7".equals(zAssayResult.getAssayItem())).findFirst();
@@ -185,7 +185,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setYxsyResultConcentration(resultConcentration);
                 Double yxsyStandardVal = assayDetailRes.getYxsyStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - yxsyStandardVal) / yxsyStandardVal);
+                assayDetailRes.setYxsyDeviationRate((resultConcentration - yxsyStandardVal) / yxsyStandardVal);
             }
             //硝酸盐氮
             Optional<ZAssayResult> xsydOptional = zAssayResults.stream().filter(zAssayResult -> "8".equals(zAssayResult.getAssayItem())).findFirst();
@@ -194,7 +194,7 @@ public class BusinessServiceImpl implements IBusinessService {
                 Double resultConcentration = zAssayResult.getResultConcentration();
                 assayDetailRes.setXsydResultConcentration(resultConcentration);
                 Double xsydStandardVal = assayDetailRes.getXsydStandardVal();
-                assayDetailRes.setHighCodDeviationRate((resultConcentration - xsydStandardVal) / xsydStandardVal);
+                assayDetailRes.setXsydDeviationRate((resultConcentration - xsydStandardVal) / xsydStandardVal);
             }
         }
     }