Преглед изворни кода

[task-1766] 性能验证模块 开发 (二期) / 添加新的验证方法和新的配置detail表

Li Yuan пре 1 година
родитељ
комит
4946251dce
14 измењених фајлова са 583 додато и 172 уклоњено
  1. 5 7
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/pv/persistence/entity/ExperimentalConfigDetailTbl.java
  2. 23 51
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/pv/persistence/entity/ExperimentalConfigTbl.java
  3. 251 0
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/LinearRangeAverageSlope.java
  4. 82 0
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/LinearRangeRecoveryMethod.java
  5. 8 2
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/PVItemBuilder.java
  6. 74 44
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/PrecisionEP15.java
  7. 8 1
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/PrecisionRepeatability.java
  8. 60 1
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/TruenessBiasAssessment.java
  9. 8 0
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/TruenessEP15Patient.java
  10. 6 0
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/TruenessRefernece.java
  11. 12 0
      ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/report/TableDTO.java
  12. 37 41
      ibps-provider-root/modules/provider-business/src/main/resources/com/lc/ibps/pv/persistence/mapping/ExperimentalConfig.map.xml
  13. 4 4
      ibps-provider-root/modules/provider-business/src/main/resources/com/lc/ibps/pv/persistence/mapping/ExperimentalConfigDetail.map.xml
  14. 5 21
      ibps-provider-root/modules/provider-business/src/main/resources/pv/report/precisionEP15A2.ftl

+ 5 - 7
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/pv/persistence/entity/ExperimentalConfigDetailTbl.java

@@ -1,7 +1,5 @@
 package com.lc.ibps.components.pv.persistence.entity;
 
-import java.util.Date;
-
 import com.lc.ibps.base.framework.persistence.entity.AbstractPo;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
@@ -35,7 +33,7 @@ public class ExperimentalConfigDetailTbl extends AbstractPo<String>{
 	@ApiModelProperty(value = "是否基础")
 	protected String  isBasic; 		/*是否基础*/
 	@ApiModelProperty(value = "是否禁用")
-	protected String  idDisabled; 		/*是否禁用*/
+	protected String isDisabled; 		/*是否禁用*/
 	@ApiModelProperty(value = "是否公开")
 	protected String  isPublic; 		/*是否公开*/
 	@ApiModelProperty(value = "实验步骤")
@@ -153,17 +151,17 @@ public class ExperimentalConfigDetailTbl extends AbstractPo<String>{
 	{
 		return this.isBasic;
 	}
-	public void setIdDisabled(String idDisabled) 
+	public void setIsDisabled(String isDisabled)
 	{
-		this.idDisabled = idDisabled;
+		this.isDisabled = isDisabled;
 	}
 	/**
 	 * 返回 是否禁用
 	 * @return
 	 */
-	public String getIdDisabled() 
+	public String getIsDisabled()
 	{
-		return this.idDisabled;
+		return this.isDisabled;
 	}
 	public void setIsPublic(String isPublic) 
 	{

+ 23 - 51
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/pv/persistence/entity/ExperimentalConfigTbl.java

@@ -8,11 +8,11 @@ import io.swagger.annotations.ApiModelProperty;
 
 /**
  * 性能验证配置信息 表对象
- * 
+ *
  *<pre> 
  * 开发公司:深圳市金源信通科技有限公司
  * 开发人员:codegen
- * 创建时间:2024-05-29 08:52:32
+ * 创建时间:2024-05-29 13:50:54
  *</pre>
  */
 @SuppressWarnings("serial")
@@ -24,12 +24,8 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	protected String  tenantId; 		/*租户ID*/
 	@ApiModelProperty(value = "IP地址")
 	protected String  ip; 		/*IP地址*/
-	@ApiModelProperty(value = "是否过审")
-	protected String  shiFouGuoShen; 		/*是否过审*/
 	@ApiModelProperty(value = "地点")
 	protected String  diDian; 		/*地点*/
-	@ApiModelProperty(value = "快照")
-	protected String  kuaiZhao; 		/*快照*/
 	@ApiModelProperty(value = "类型")
 	protected String  type; 		/*类型*/
 	@ApiModelProperty(value = "指标")
@@ -43,7 +39,7 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	@ApiModelProperty(value = "编码")
 	protected String  targetKey; 		/*编码*/
 
-	public void setId(String id) 
+	public void setId(String id)
 	{
 		this.id = id;
 	}
@@ -51,11 +47,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 主键
 	 * @return
 	 */
-	public String getId() 
+	public String getId()
 	{
 		return this.id;
 	}
-	public void setTenantId(String tenantId) 
+	public void setTenantId(String tenantId)
 	{
 		this.tenantId = tenantId;
 	}
@@ -63,11 +59,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 租户ID
 	 * @return
 	 */
-	public String getTenantId() 
+	public String getTenantId()
 	{
 		return this.tenantId;
 	}
-	public void setIp(String ip) 
+	public void setIp(String ip)
 	{
 		this.ip = ip;
 	}
@@ -75,23 +71,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 IP地址
 	 * @return
 	 */
-	public String getIp() 
+	public String getIp()
 	{
 		return this.ip;
 	}
-	public void setShiFouGuoShen(String shiFouGuoShen) 
-	{
-		this.shiFouGuoShen = shiFouGuoShen;
-	}
-	/**
-	 * 返回 是否过审
-	 * @return
-	 */
-	public String getShiFouGuoShen() 
-	{
-		return this.shiFouGuoShen;
-	}
-	public void setDiDian(String diDian) 
+	public void setDiDian(String diDian)
 	{
 		this.diDian = diDian;
 	}
@@ -99,23 +83,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 地点
 	 * @return
 	 */
-	public String getDiDian() 
+	public String getDiDian()
 	{
 		return this.diDian;
 	}
-	public void setKuaiZhao(String kuaiZhao) 
-	{
-		this.kuaiZhao = kuaiZhao;
-	}
-	/**
-	 * 返回 快照
-	 * @return
-	 */
-	public String getKuaiZhao() 
-	{
-		return this.kuaiZhao;
-	}
-	public void setType(String type) 
+	public void setType(String type)
 	{
 		this.type = type;
 	}
@@ -123,11 +95,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 类型
 	 * @return
 	 */
-	public String getType() 
+	public String getType()
 	{
 		return this.type;
 	}
-	public void setTarget(String target) 
+	public void setTarget(String target)
 	{
 		this.target = target;
 	}
@@ -135,11 +107,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 指标
 	 * @return
 	 */
-	public String getTarget() 
+	public String getTarget()
 	{
 		return this.target;
 	}
-	public void setSn(String sn) 
+	public void setSn(String sn)
 	{
 		this.sn = sn;
 	}
@@ -147,11 +119,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 排序
 	 * @return
 	 */
-	public String getSn() 
+	public String getSn()
 	{
 		return this.sn;
 	}
-	public void setConfig(String config) 
+	public void setConfig(String config)
 	{
 		this.config = config;
 	}
@@ -159,11 +131,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 配置(废弃)
 	 * @return
 	 */
-	public String getConfig() 
+	public String getConfig()
 	{
 		return this.config;
 	}
-	public void setIcon(String icon) 
+	public void setIcon(String icon)
 	{
 		this.icon = icon;
 	}
@@ -171,11 +143,11 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 图标
 	 * @return
 	 */
-	public String getIcon() 
+	public String getIcon()
 	{
 		return this.icon;
 	}
-	public void setTargetKey(String targetKey) 
+	public void setTargetKey(String targetKey)
 	{
 		this.targetKey = targetKey;
 	}
@@ -183,9 +155,9 @@ public class ExperimentalConfigTbl extends AbstractPo<String>{
 	 * 返回 编码
 	 * @return
 	 */
-	public String getTargetKey() 
+	public String getTargetKey()
 	{
 		return this.targetKey;
 	}
-	
+
 }

+ 251 - 0
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/LinearRangeAverageSlope.java

@@ -0,0 +1,251 @@
+package com.lc.ibps.components.verification.model2;
+
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.serializer.SerializerFeature;
+import com.lc.ibps.components.verification.model.InspectionConfigVO;
+import com.lc.ibps.components.verification.regression.PolynomialRegression;
+import com.lc.ibps.components.verification.report.*;
+import org.apache.commons.lang3.ArrayUtils;
+import org.apache.commons.math3.stat.StatUtils;
+import org.apache.commons.math3.stat.descriptive.DescriptiveStatistics;
+
+import java.time.LocalDate;
+import java.util.*;
+
+public class LinearRangeAverageSlope extends PVModel {
+
+    private final double[] means;
+    private final double[][] diffs;
+    private final double[][] dli;
+    private double maxDli;
+    private double mean;
+    private final double[] standardDeviations;
+
+    private double[] targetValues;
+    private boolean isTarget = true;
+
+
+    private final PolynomialRegression pr1 = new PolynomialRegression();
+
+    private final double claimValue;
+
+
+    private double sdr;
+    private double cvr;
+
+    public LinearRangeAverageSlope(double[][] data, InspectionConfigVO configVO) {
+        super(data, configVO);
+
+        this.means = new double[this.specimensNum];
+        this.standardDeviations = new double[this.specimensNum];
+        this.claimValue = configVO.getClaimValue();
+        this.diffs = new double[5][this.specimensNum];
+        this.dli = new double[5][this.specimensNum];
+        this.targetValues = new double[this.specimensNum];
+        calcTarget(configVO.getTargetValue());
+    }
+
+    @Override
+    public void calculate() {
+
+        for (int i = 0; i < specimensNum; i++) {
+            DescriptiveStatistics stat = new DescriptiveStatistics(data[i]);
+            means[i] = stat.getMean();
+            standardDeviations[i] = stat.getStandardDeviation();
+            if (repeatNum == 2) {
+                diffs[1][i] = data[i][0] - data[i][1];  //diff
+                diffs[2][i] = Math.pow(diffs[1][i], 2) / 2; //diff * diff / 2
+                diffs[3][i] = diffs[1][i] / means[i];  //%diff
+                diffs[4][i] = Math.pow(diffs[3][i], 2) / 2; //%diff * %diff /2
+            }
+
+        }
+        diffs[0] = means;
+        mean = StatUtils.mean(means);
+        sdr = Math.sqrt(StatUtils.mean(diffs[2])) * 100;
+        cvr = Math.sqrt(StatUtils.mean(diffs[4])) * 100;
+        //TODO: check cvr
+
+        pr1.addData(targetValues, means, repeatNum, 1);
+
+    }
+
+    private void calcTarget(double[] targets) {
+        if (ArrayUtils.isEmpty(targets)) {
+            for (int i = 0; i < specimensNum; i++) {
+                targetValues[i] = i + 1;
+            }
+            isTarget = false;
+        } else if (targets.length == 2) {
+            targetValues[0] = targets[0];
+            targetValues[specimensNum - 1] = targets[1];
+            int range = specimensNum - 1;
+            for (int i = 1; i < range; i++) {
+                targetValues[i] = format(targets[0] * (range - i) / range + targets[1] * i / range, 2);
+            }
+        } else if (targets.length == specimensNum) {
+            targetValues = targets;
+        }
+    }
+
+    public TableDTO buildDataTableDTO() {
+        List<String> header = new ArrayList<String>();
+
+        header.add("标本号");
+        if (isTarget) header.add("目标值");
+        for (int i = 1; i <= repeatNum; i++) {
+            header.add(String.format("重复#%d", i));
+        }
+        TableDTO table = new TableDTO();
+        table.buildHeader(header.toArray(new String[header.size()]));
+
+        String[][] r = new String[specimensNum][];
+        for (int i = 0; i < data.length; i++) {
+            List<String> rl = new ArrayList();
+            rl.add(String.valueOf(i + 1));
+            if (isTarget) rl.add(String.valueOf(targetValues[i]));
+
+            for (int j = 0; j < data[i].length; j++) {
+                rl.add(format(data[i][j]));
+            }
+            r[i] = rl.toArray(new String[rl.size()]);
+        }
+        table.buildData(r);
+        return table;
+    }
+
+    @Override
+    public SheetDTO[] buildSheetDTO() {
+        SheetDTO sheet = new SheetDTO("平均斜率");
+        sheet.setReportDataDTO(buildReportTableDTO());
+        sheet.setChartDataDTO(buildChartDTO());
+        return new SheetDTO[]{sheet};
+    }
+
+    @Override
+    public String generateResult() {
+        return null;
+    }
+
+    public Map<String, TableDTO> buildReportTableDTO() {
+        Map<String, TableDTO> reports = new HashMap<>();
+        reports.put("表1: 重复性差异检测结果", buildTable1DTO());
+        reports.put("表2: 多项式回归分析结果", buildTable2DTO());
+        reports.put("表3: 线性偏离计算结果", buildTable3DTO());
+        return reports;
+    }
+
+    public Map<String, ChartDTO> buildChartDTO() {
+        Map<String, ChartDTO> charts = new HashMap<>();
+        charts.put("图1: 线性实验", buildChart1DTO());
+        charts.put("图2: 线性评价差值点图", buildChart2DTO());
+        return charts;
+    }
+
+    private ChartDTO buildChart2DTO() {
+        ChartDTO chartDTO = new ChartDTO("linesForRange");
+        double[][] data = new double[targetValues.length][2];
+        for (int i = 0; i < data.length; i++) {
+            data[i] = new double[]{i + 1, diffs[1][i]};
+        }
+//        chartDTO.setData(data);
+        final HashMap<String, Object> config = new HashMap<>();
+        config.put("yAxisUp", 0.1);
+        config.put("yAxisLow", -0.1);
+        config.put("data", JSONObject.toJSONString(data, SerializerFeature.DisableCircularReferenceDetect));
+
+        chartDTO.setOption(EchartsFreemarkerUtils.generateChart("/scatter/linesForRange.ftl", config));
+        return chartDTO;
+    }
+
+    private ChartDTO buildChart1DTO() {
+        ChartDTO chartDTO = new ChartDTO("polynomialRegression");
+        double[][] data = new double[targetValues.length][2];
+        for (int i = 0; i < data.length; i++) {
+            data[i] = new double[]{targetValues[i], means[i]};
+        }
+//        chartDTO.setData(data);
+        Map<String, Object> map = new HashMap<>();
+        map.put("data", JSONObject.toJSONString(data, SerializerFeature.DisableCircularReferenceDetect));
+        chartDTO.setOption(EchartsFreemarkerUtils.generateChart("/scatter/polynomialRegression.ftl", map));
+        return chartDTO;
+    }
+
+    private TableDTO buildTable1DTO() {
+
+        TableDTO table = new TableDTO();
+        String[] header = {"标本号", "均值", "差值Diff", "Diff<sup>2</sup>/2", "%Diff", "%Diff<sup>2</sup>/2"};
+        table.buildHeader(header);
+
+
+        double[][] r = new double[specimensNum][6];
+        double[][] doubles = transposeMatrix(diffs);
+
+        for (int i = 0; i < doubles.length; i++) {
+            r[i] = ArrayUtils.add(doubles[i], 0, i + 1);
+        }
+        table.buildData(r, getScale());
+        return table;
+    }
+
+    private TableDTO buildTable2DTO() {
+
+        TableDTO table = new TableDTO();
+        String[] header = {"阶别", "系数", "系数值", "SE<sub>i</sub>", "t 检验", "S<sub>y.x</sub>", "自由度"};
+        table.buildHeader(header);
+        table.getHeader()[0].put("merge", "true");
+        table.getHeader()[5].put("merge", "true");
+        table.getHeader()[6].put("merge", "true");
+        String[][] r = new String[9][7];
+        int i = 0;
+        for (int j = 0; j < pr1.getParameters().length; j++) {
+            r[i][0] = "1";
+            r[i][1] = String.format("b%d", j);
+            r[i][2] = format(pr1.getParameters()[j]);
+            r[i][3] = format(pr1.getStdErrors()[j]);
+            r[i][4] = format(pr1.gettValues()[j]);
+            r[i][5] = format((pr1.getStdError()));
+            r[i][6] = pr1.getDfDependent().toString();
+            i++;
+        }
+
+        table.buildData(r);
+        return table;
+    }
+
+    private TableDTO buildTable3DTO() {
+
+        TableDTO table = new TableDTO();
+        String[] header = {"标本号", "x<sub>i</sub>", "p(x<sub>i</sub>)", "b<sub>0</sub>+b<sub>1</sub>x<sub>i</sub>", "DL<sub>i</sub>", "%DL<sub>i</sub>"};
+        table.buildHeader(header);
+
+        double[][] r = new double[specimensNum][6];
+        double[][] doubles = transposeMatrix(dli);
+
+        for (int i = 0; i < doubles.length; i++) {
+            r[i] = ArrayUtils.add(doubles[i], 0, i + 1);
+        }
+        table.buildData(r, getScale());
+        return table;
+    }
+
+    public static void main(String[] args) {
+        InspectionConfigVO config = new InspectionConfigVO("平均斜率", 1, 6,
+                null, 2, LocalDate.now(), true);
+        config.setTargetValue(new double[]{0, 24.56});
+        double[][] data = {{-0.01, -0.01}, {5.00, 4.99}, {10.18, 10.05}, {14.65, 14.65}, {19.57, 19.65}, {24.02, 24.09}};
+        LinearRangeAverageSlope ep6 = new LinearRangeAverageSlope(data, config);
+        TableDTO tableDTO = ep6.buildDataTableDTO();
+        Map<String, TableDTO> stringTableDTOMap = ep6.buildReportTableDTO();
+        final Map<String, ChartDTO> stringChartDTOMap = ep6.buildChartDTO();
+        ReportDataDTO report = new ReportDataDTO();
+
+
+        report.setDataDTO(tableDTO);
+//        report.setReportDataDTO(stringTableDTOMap);
+        String s = JSONObject.toJSONString(report, SerializerFeature.DisableCircularReferenceDetect);
+
+        System.out.println(s);
+
+    }
+}

+ 82 - 0
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/LinearRangeRecoveryMethod.java

@@ -0,0 +1,82 @@
+package com.lc.ibps.components.verification.model2;
+
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.serializer.SerializerFeature;
+import com.lc.ibps.components.verification.model.InspectionConfigVO;
+import com.lc.ibps.components.verification.regression.PolynomialRegression;
+import com.lc.ibps.components.verification.report.*;
+import org.apache.commons.lang3.ArrayUtils;
+import org.apache.commons.math3.stat.StatUtils;
+import org.apache.commons.math3.stat.descriptive.DescriptiveStatistics;
+
+import java.time.LocalDate;
+import java.util.*;
+
+public class LinearRangeRecoveryMethod extends LinearRangeAverageSlope {
+
+
+    public LinearRangeRecoveryMethod(double[][] data, InspectionConfigVO configVO) {
+        super(data, configVO);
+
+
+    }
+
+    @Override
+    public void calculate() {
+
+    }
+
+
+    public TableDTO buildDataTableDTO() {
+        return null;
+    }
+
+    @Override
+    public SheetDTO[] buildSheetDTO() {
+        SheetDTO sheet = new SheetDTO("线性稀释回收法");
+        sheet.setReportDataDTO(buildReportTableDTO());
+        sheet.setChartDataDTO(buildChartDTO());
+        return new SheetDTO[]{sheet};
+    }
+
+    @Override
+    public String generateResult() {
+        return null;
+    }
+
+    public Map<String, TableDTO> buildReportTableDTO() {
+        Map<String, TableDTO> reports = new HashMap<>();
+//        reports.put("表1: 重复性差异检测结果", buildTable1DTO());
+//        reports.put("表2: 多项式回归分析结果", buildTable2DTO());
+//        reports.put("表3: 线性偏离计算结果", buildTable3DTO());
+        return reports;
+    }
+
+    public Map<String, ChartDTO> buildChartDTO() {
+        Map<String, ChartDTO> charts = new HashMap<>();
+//        charts.put("图1: 线性实验", buildChart1DTO());
+//        charts.put("图2: 线性评价差值点图", buildChart2DTO());
+        return charts;
+    }
+
+
+    public static void main(String[] args) {
+        InspectionConfigVO config = new InspectionConfigVO("线性稀释回收法", 1, 6,
+                null, 2, LocalDate.now(), true);
+        config.setTargetValue(new double[]{0, 24.56});
+        double[][] data = {{-0.01, -0.01}, {5.00, 4.99}, {10.18, 10.05}, {14.65, 14.65}, {19.57, 19.65}, {24.02, 24.09}};
+        LinearRangeRecoveryMethod ep6 = new LinearRangeRecoveryMethod(data, config);
+        TableDTO tableDTO = ep6.buildDataTableDTO();
+        Map<String, TableDTO> stringTableDTOMap = ep6.buildReportTableDTO();
+        final Map<String, ChartDTO> stringChartDTOMap = ep6.buildChartDTO();
+        ReportDataDTO report = new ReportDataDTO();
+
+
+        report.setDataDTO(tableDTO);
+//        report.setReportDataDTO(stringTableDTOMap);
+        String s = JSONObject.toJSONString(report, SerializerFeature.DisableCircularReferenceDetect);
+
+        System.out.println(s);
+
+    }
+}

+ 8 - 2
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/PVItemBuilder.java

@@ -94,14 +94,20 @@ public class PVItemBuilder {
 //        PVModel pvModel;
         if (config.getKey().equals("精密度验证")) {
             pvModel = new PrecisionEP15(dataArrays, config);
+        }  else if (config.getKey().equals("重复性验证")) {
+            pvModel = new PrecisionRepeatability(dataArrays, config);
         } else if (config.getKey().equals("使用定值参考物质验证")) {
             pvModel = new TruenessRefernece(dataArrays, config);
         } else if (config.getKey().equals("使用患者样品验证")) {
             pvModel = new TruenessEP15Patient(dataArrays, config);
+        } else if(config.getKey().equals("CNAS-GL037偏倚评估")){
+            pvModel = new TruenessBiasAssessment(dataArrays,config);
         } else if (config.getKey().equals("408线性评价")) {
             pvModel = new LinearRangeEP6A(dataArrays, config);
-        } else if (config.getKey().equals("重复性验证")) {
-            pvModel = new PrecisionRepeatability(dataArrays, config);
+        } else if(config.getKey().equals("平均斜率评价法")){
+            pvModel = new LinearRangeAverageSlope(dataArrays,config);
+        } else if(config.getKey().equals("线性稀释回收法")){
+            pvModel = new LinearRangeRecoveryMethod(dataArrays,config);
         } else {
             return null;
         }

+ 74 - 44
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/PrecisionEP15.java

@@ -1,12 +1,16 @@
 package com.lc.ibps.components.verification.model2;
 
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.serializer.SerializerFeature;
 import com.lc.ibps.components.verification.model.InspectionConfigVO;
-import com.lc.ibps.components.verification.report.EchartsFreemarkerUtils;
-import com.lc.ibps.components.verification.report.SheetDTO;
-import com.lc.ibps.components.verification.report.TableDTO;
+import com.lc.ibps.components.verification.report.*;
+import org.apache.commons.lang3.ArrayUtils;
+import org.apache.commons.lang3.RandomUtils;
 import org.apache.commons.math3.linear.MatrixUtils;
 import org.apache.commons.math3.linear.RealMatrix;
+import org.apache.commons.math3.linear.RealMatrixFormat;
 
+import java.text.DecimalFormat;
 import java.time.LocalDate;
 import java.util.*;
 
@@ -30,24 +34,7 @@ public class PrecisionEP15 extends PVModel {
         items.stream().forEach(i->i.calculate());
     }
 
-    public static void main(String[] args) {
-        InspectionConfigVO config = new InspectionConfigVO("精密度", 5, 2,
-                null, 3, LocalDate.now(), true);
-        config.setRange(99);
-        config.setBatchCVSValue(3.2);
-        config.setDailyCVSValue(3.1);
-        double[][] data = {
-                {3.3, 3.23, 3.43, 3.3, 3.23, 3.43},
-                {3.21, 3.45, 3.42, 3.3, 3.23, 3.43},
-                {3.21, 3.24, 3.45, 3.3, 3.23, 3.43},
-                {3.5, 3.45, 3.51, 3.3, 3.23, 3.43},
-                {3.33, 3.45, 3.32, 3.3, 3.23, 3.43}};
-        PrecisionEP15 precisionEP15 = new PrecisionEP15(data, config);
-        TableDTO tableDTO = precisionEP15.buildDataTableDTO();
-        SheetDTO[] sheetDTOS = precisionEP15.buildSheetDTO();
-        String s = precisionEP15.generateResult();
-        System.out.println(s);
-    }
+
 
     @Override
     public TableDTO buildDataTableDTO() {
@@ -83,16 +70,9 @@ public class PrecisionEP15 extends PVModel {
 
     @Override
     public SheetDTO[] buildSheetDTO() {
-        SheetDTO[] reports = new SheetDTO[items.size()];
-        for (int i = 0; i < items.size(); i++) {
-            final SheetDTO sheet = new SheetDTO(items.get(i).name);
-            Map<String, TableDTO> table = new HashMap<>();
-            table.putAll(buildTable1DTO(items.get(i)));
-            sheet.setReportDataDTO(table);
-            reports[i] = sheet;
-        }
-
-        return reports;
+        SheetDTO sheet = new SheetDTO("精密度验证");
+        sheet.setReportDataDTO(buildReportTableDTO());
+        return new SheetDTO[]{sheet};
     }
 
     @Override
@@ -101,21 +81,71 @@ public class PrecisionEP15 extends PVModel {
 
     }
 
-    private Map<String, TableDTO> buildTable1DTO(PrecisionEP15Item item) {
+    private Map<String, TableDTO> buildReportTableDTO() {
         Map<String, TableDTO> reports = new HashMap<>();
         TableDTO table = new TableDTO();
-        String[][] data = new String[8][2];
-
-        data[0] = new String[]{"总均值", format(item.getMean())};
-        data[1] = new String[]{"批内方差 (V<sub>r</sub>)", format(item.getVr())};
-        data[2] = new String[]{"批内标准差 (SD<sub>r</sub>)", format(item.getSdr())};
-        data[3] = new String[]{"批内变异系数 (CV<sub>r</sub>)", format(item.getCvr())};
-        data[4] = new String[]{"批间标准差 (SD<sub>b</sub>)", format(item.getSdb())};
-        data[5] = new String[]{"批间方差 (V<sub>b</sub>)", format(item.getVb())};
-        data[6] = new String[]{"实验室内标准差 (SD<sub>1</sub>)", format(item.getSdl())};
-        data[7] = new String[]{"实验室变异系数 (CV)", format(item.getCvl())};
-        table.buildData(data);
-        reports.put(item.name, table);
+//        String[][] data = new String[8][2];
+//
+//        data[0] = new String[]{"总均值", format(item.getMean())};
+//        data[1] = new String[]{"批内方差 (V<sub>r</sub>)", format(item.getVr())};
+//        data[2] = new String[]{"批内标准差 (SD<sub>r</sub>)", format(item.getSdr())};
+//        data[3] = new String[]{"批内变异系数 (CV<sub>r</sub>)", format(item.getCvr())};
+//        data[4] = new String[]{"批间标准差 (SD<sub>b</sub>)", format(item.getSdb())};
+//        data[5] = new String[]{"批间方差 (V<sub>b</sub>)", format(item.getVb())};
+//        data[6] = new String[]{"实验室内标准差 (SD<sub>1</sub>)", format(item.getSdl())};
+//        data[7] = new String[]{"实验室变异系数 (CV)", format(item.getCvl())};
+//        table.buildData(data);
+//        reports.put(item.name, table);
+
+        String[] header = {"样本名", "总均值", "批内标准差S<sub>r</sub>", "批内CV<sub>r</sub>","验证值<sub>批内</sub>",
+                "批间方差 V<sub>b</sub>","室内标准差S<sub>l</sub>","室内CV<sub>l</sub>","验证值<sub>室内</sub>"};
+        table.buildHeader(header);
+        String[][] d = new String[specimensNum][9];
+        for (int i = 0; i < d.length; i++) {
+            String[] subData = new String[9];
+            subData[0] = specimensName[i];
+            subData[1] =  format(items.get(i).getMean());
+            subData[2] = format(items.get(i).getSdr());
+            subData[3] =  format(items.get(i).getCvr());
+            subData[4] = format(items.get(i).getVerR());
+            subData[5] = format(items.get(i).getVb());
+            subData[6] = format(items.get(i).getSdl());
+            subData[7] =  format(items.get(i).getCvl());
+            subData[8] = format(items.get(i).getVerL());;
+            d[i] = subData;
+        }
+        table.buildData(d);
+        reports.put("表1: 精密度验证结果", table);
         return reports;
     }
+
+    public static void main(String[] args) {
+        InspectionConfigVO config = new InspectionConfigVO("精密度", 5, 2,
+                null, 3, LocalDate.now(), true);
+        config.setRange(99);
+        config.setBatchCVSValue(3.2);
+        config.setDailyCVSValue(3.1);
+        config.setDecimal(3);
+        config.setUnits("mmg/L");
+        config.setKey("精密度验证");
+        RandomUtils.nextDouble();
+        double[][] data = new double[config.getDays()][config.getRepeatNum()*config.getSpecimensNum()];
+        for (int i = 0; i < config.getDays(); i++) {
+            for (int j = 0; j < config.getRepeatNum()*config.getSpecimensNum(); j++) {
+                data[i][j] = RandomUtils.nextDouble(3.12,3.45);
+            }
+        }
+        RealMatrix matrix = MatrixUtils.createRealMatrix(data);
+        RealMatrixFormat matrixFormat = new RealMatrixFormat("", "", "", "\n",
+                "", ",",new DecimalFormat( "0.00" ));
+        System.out.println(matrixFormat.format(matrix));
+
+        PVItemBuilder pvItemBuilder = PVItemBuilder.getInstance(config);
+        pvItemBuilder.buildPVModel(data);
+        ReportDataDTO dataDTO = ReportFactory.build(pvItemBuilder);
+        String s = JSONObject.toJSONString(dataDTO, SerializerFeature.DisableCircularReferenceDetect);
+        String s1 = pvItemBuilder.getPvModel().generateResult();
+        System.out.println(s);
+        System.out.println(s1);
+    }
 }

+ 8 - 1
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/PrecisionRepeatability.java

@@ -6,8 +6,12 @@ import com.lc.ibps.components.verification.model.InspectionConfigVO;
 import com.lc.ibps.components.verification.report.*;
 import org.apache.commons.lang3.ArrayUtils;
 import org.apache.commons.lang3.RandomUtils;
+import org.apache.commons.math3.linear.MatrixUtils;
+import org.apache.commons.math3.linear.RealMatrix;
+import org.apache.commons.math3.linear.RealMatrixFormat;
 import org.apache.commons.math3.stat.descriptive.DescriptiveStatistics;
 
+import java.text.DecimalFormat;
 import java.time.LocalDate;
 import java.util.ArrayList;
 import java.util.HashMap;
@@ -159,7 +163,10 @@ public class PrecisionRepeatability extends PVModel{
                 data[i][j] = RandomUtils.nextDouble(3.12,3.45);
             }
         }
-        System.out.println(ArrayUtils.toString(data));
+        RealMatrix matrix = MatrixUtils.createRealMatrix(data);
+        RealMatrixFormat matrixFormat = new RealMatrixFormat("", "", "", "\n",
+                "", ",",new DecimalFormat( "0.00" ));
+        System.out.println(matrixFormat.format(matrix));
         PVItemBuilder pvItemBuilder = PVItemBuilder.getInstance(config);
         pvItemBuilder.buildPVModel(data);
         ReportDataDTO dataDTO = ReportFactory.build(pvItemBuilder);

+ 60 - 1
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/TruenessBiasAssessment.java

@@ -1,12 +1,26 @@
 package com.lc.ibps.components.verification.model2;
 
+import com.alibaba.fastjson.JSONObject;
+import com.alibaba.fastjson.serializer.SerializerFeature;
 import com.lc.ibps.components.verification.model.InspectionConfigVO;
+import com.lc.ibps.components.verification.report.ReportDataDTO;
+import com.lc.ibps.components.verification.report.ReportFactory;
 import com.lc.ibps.components.verification.report.SheetDTO;
 import com.lc.ibps.components.verification.report.TableDTO;
+import org.apache.commons.lang3.ArrayUtils;
+import org.apache.commons.lang3.RandomUtils;
+import org.apache.commons.math3.linear.MatrixUtils;
+import org.apache.commons.math3.linear.RealMatrix;
+import org.apache.commons.math3.linear.RealMatrixFormat;
+
+import java.text.DecimalFormat;
+import java.time.LocalDate;
+import java.util.*;
 
 public class TruenessBiasAssessment extends PVModel{
     private double[] targetValues;
     private double tea;
+    private double bias;
     public TruenessBiasAssessment(double[][] data, InspectionConfigVO configVO) {
         super(data, configVO);
     }
@@ -18,7 +32,23 @@ public class TruenessBiasAssessment extends PVModel{
 
     @Override
     public TableDTO buildDataTableDTO() {
-        return null;
+        String[] h = new String[specimensName.length + 1];
+        Map<String, String[]> child = new HashMap<>();
+        String[] c = new String[repeatNum];
+        for (int i = 0; i < c.length; i++) {
+            c[i] = String.format("重复 %d", (i + 1));
+        }
+        h[0] = "天数";
+        for (int i = 0; i < specimensName.length; i++) {
+            h[1 + i] = specimensName[i];
+            child.put(h[i + 1], c);
+        }
+        TableDTO table = new TableDTO();
+        table.buildHeader(h, child);
+
+        table.buildDataWithIndex(data, getScale());
+        return table;
+
     }
 
     @Override
@@ -30,4 +60,33 @@ public class TruenessBiasAssessment extends PVModel{
     public String generateResult() {
         return null;
     }
+
+    public static void main(String[] args) {
+        InspectionConfigVO config = new InspectionConfigVO("偏倚评估", 5, 2,
+                null, 2, LocalDate.now(), true);
+        config.setRange(99);
+        config.setBatchCVSValue(3.2);
+        config.setDailyCVSValue(3.1);
+        config.setDecimal(3);
+        config.setUnits("mmg/L");
+        config.setKey("CNAS-GL037偏倚评估");
+        RandomUtils.nextDouble();
+        double[][] data = new double[config.getDays()][config.getRepeatNum()*config.getSpecimensNum()];
+        for (int i = 0; i < config.getDays(); i++) {
+            for (int j = 0; j < config.getRepeatNum()*config.getSpecimensNum(); j++) {
+                data[i][j] = RandomUtils.nextDouble(3.12,3.45);
+            }
+        }
+        RealMatrix matrix = MatrixUtils.createRealMatrix(data);
+        RealMatrixFormat matrixFormat = new RealMatrixFormat("", "", "", "\n",
+                "", ",",new DecimalFormat( "0.00" ));
+        System.out.println(matrixFormat.format(matrix));
+        PVItemBuilder pvItemBuilder = PVItemBuilder.getInstance(config);
+        pvItemBuilder.buildPVModel(data);
+        ReportDataDTO dataDTO = ReportFactory.build(pvItemBuilder);
+        String s = JSONObject.toJSONString(dataDTO, SerializerFeature.DisableCircularReferenceDetect);
+        String s1 = pvItemBuilder.getPvModel().generateResult();
+        System.out.println(s);
+        System.out.println(s1);
+    }
 }

+ 8 - 0
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/TruenessEP15Patient.java

@@ -7,9 +7,13 @@ import com.lc.ibps.components.verification.report.ChartDTO;
 import com.lc.ibps.components.verification.report.EchartsFreemarkerUtils;
 import com.lc.ibps.components.verification.report.SheetDTO;
 import com.lc.ibps.components.verification.report.TableDTO;
+import org.apache.commons.math3.linear.MatrixUtils;
+import org.apache.commons.math3.linear.RealMatrix;
+import org.apache.commons.math3.linear.RealMatrixFormat;
 import org.apache.commons.math3.stat.StatUtils;
 import org.apache.commons.math3.stat.descriptive.DescriptiveStatistics;
 
+import java.text.DecimalFormat;
 import java.time.LocalDate;
 import java.util.HashMap;
 import java.util.Map;
@@ -264,6 +268,10 @@ public class TruenessEP15Patient extends PVModel {
                 {180, 183},
                 {210, 202},
                 {435, 430}};
+        RealMatrix matrix = MatrixUtils.createRealMatrix(data);
+        RealMatrixFormat matrixFormat = new RealMatrixFormat("", "", "", "\n",
+                "", ",",new DecimalFormat( "0.00" ));
+        System.out.println(matrixFormat.format(matrix));
         TruenessEP15Patient tr = new TruenessEP15Patient(transposeMatrix(data), config);
 
         TableDTO tableDTO = tr.buildDataTableDTO();

+ 6 - 0
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/model2/TruenessRefernece.java

@@ -6,7 +6,9 @@ import com.lc.ibps.components.verification.report.SheetDTO;
 import com.lc.ibps.components.verification.report.TableDTO;
 import org.apache.commons.math3.linear.MatrixUtils;
 import org.apache.commons.math3.linear.RealMatrix;
+import org.apache.commons.math3.linear.RealMatrixFormat;
 
+import java.text.DecimalFormat;
 import java.time.LocalDate;
 import java.util.*;
 
@@ -127,6 +129,10 @@ public class TruenessRefernece extends PVModel {
                 {2.09, 1.98, 2.04, 2.09},
                 {2.15, 2.09, 2.04, 2.09},
                 {2.09, 2.04, 2.04, 2.09}};
+        RealMatrix matrix = MatrixUtils.createRealMatrix(data);
+        RealMatrixFormat matrixFormat = new RealMatrixFormat("", "", "", "\n",
+                "", ",",new DecimalFormat( "0.00" ));
+        System.out.println(matrixFormat.format(matrix));
         TruenessRefernece tr = new TruenessRefernece(data, config);
         TableDTO tableDTO = tr.buildDataTableDTO();
         SheetDTO[] sheetDTOS = tr.buildSheetDTO();

+ 12 - 0
ibps-provider-root/modules/provider-business/src/main/java/com/lc/ibps/components/verification/report/TableDTO.java

@@ -65,6 +65,18 @@ public class TableDTO {
         }
     }
 
+    public void buildDataWithIndex(double[][] data, int scale) {
+        list = new Map[data.length];
+        for (int i = 0; i < data.length; i++) {
+            HashMap<String, Object> m = new HashMap<>();
+            m.put(String.valueOf((char) (65)), i+1);
+            for (int j = 1; j <= data[0].length; j++) {
+                m.put(String.valueOf((char) (65 + j)), PVModel.format(data[i][j-1], scale));
+            }
+            list[i] = m;
+        }
+    }
+
     public Map<String, Object>[] getHeader() {
         return header;
     }

+ 37 - 41
ibps-provider-root/modules/provider-business/src/main/resources/com/lc/ibps/pv/persistence/mapping/ExperimentalConfig.map.xml

@@ -10,9 +10,7 @@
 		<result property="createTime" column="CREATE_TIME_" jdbcType="TIMESTAMP"/>
 		<result property="updateBy" column="UPDATE_BY_" jdbcType="VARCHAR"/>
 		<result property="updateTime" column="UPDATE_TIME_" jdbcType="TIMESTAMP"/>
-		<result property="shiFouGuoShen" column="SHI_FOU_GUO_SHEN_" jdbcType="VARCHAR"/>
 		<result property="diDian" column="DI_DIAN_" jdbcType="VARCHAR"/>
-		<result property="kuaiZhao" column="KUAI_ZHAO_" jdbcType="VARCHAR"/>
 		<result property="type" column="TYPE_" jdbcType="VARCHAR"/>
 		<result property="target" column="TARGET_" jdbcType="VARCHAR"/>
 		<result property="sn" column="SN_" jdbcType="VARCHAR"/>
@@ -20,25 +18,25 @@
 		<result property="icon" column="ICON_" jdbcType="VARCHAR"/>
 		<result property="targetKey" column="TARGET_KEY_" jdbcType="VARCHAR"/>
 	</resultMap>
-	
+
 	<sql id="columns">
-		ID_,TENANT_ID_,IP_,CREATE_BY_,CREATE_TIME_,UPDATE_BY_,UPDATE_TIME_,SHI_FOU_GUO_SHEN_,DI_DIAN_,KUAI_ZHAO_,TYPE_,TARGET_,SN_,CONFIG_,ICON_,TARGET_KEY_
+		ID_,TENANT_ID_,IP_,CREATE_BY_,CREATE_TIME_,UPDATE_BY_,UPDATE_TIME_,DI_DIAN_,TYPE_,TARGET_,SN_,CONFIG_,ICON_,TARGET_KEY_
 	</sql>
-	
+
 	<insert id="create" parameterType="com.lc.ibps.components.pv.persistence.entity.ExperimentalConfigPo">
 		INSERT INTO T_XNYZPZXX
 		(<include refid="columns"/>)
-		VALUES 
-		(#{id,jdbcType=VARCHAR}, #{tenantId,jdbcType=VARCHAR}, #{ip,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{shiFouGuoShen,jdbcType=VARCHAR}, #{diDian,jdbcType=VARCHAR}, #{kuaiZhao,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{target,jdbcType=VARCHAR}, #{sn,jdbcType=VARCHAR}, #{config,jdbcType=BLOB}, #{icon,jdbcType=VARCHAR}, #{targetKey,jdbcType=VARCHAR})
+		VALUES
+		(#{id,jdbcType=VARCHAR}, #{tenantId,jdbcType=VARCHAR}, #{ip,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{diDian,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR}, #{target,jdbcType=VARCHAR}, #{sn,jdbcType=VARCHAR}, #{config,jdbcType=BLOB}, #{icon,jdbcType=VARCHAR}, #{targetKey,jdbcType=VARCHAR})
 	</insert>
-	
+
 	<select id="get" parameterType="java.lang.String" resultMap="ExperimentalConfigPo">
-		SELECT <include refid="columns"/> FROM T_XNYZPZXX 
-		WHERE 
+		SELECT <include refid="columns"/> FROM T_XNYZPZXX
+		WHERE
 		ID_=#{id}
 	</select>
-	
-	
+
+
 	<sql id="querySql" >
 		SELECT <include refid="columns"/> FROM T_XNYZPZXX
 		<where>
@@ -53,48 +51,46 @@
 			ORDER BY ID_ DESC
 		</if>
 	</sql>
-	
+
 	<select id="query" parameterType="java.util.Map" resultMap="ExperimentalConfigPo">
 		<include refid="querySql"/>
 	</select>
-	
+
 	<select id="queryIds" parameterType="java.util.Map" resultMap="ExperimentalConfigPo">
 		SELECT ID_ FROM (<include refid="querySql"/>) T
 	</select>
-	
+
 	<select id="findByIds" resultMap="ExperimentalConfigPo">
 		SELECT <include refid="columns"/> FROM T_XNYZPZXX
-			WHERE ID_ in 
-			<foreach item="id" index="index" collection="ids" open="(" separator="," close=")">  
-				#{id}  
-			</foreach>  		
-			ORDER BY ID_ DESC			
-	</select>	
-	
+		WHERE ID_ in
+		<foreach item="id" index="index" collection="ids" open="(" separator="," close=")">
+			#{id}
+		</foreach>
+		ORDER BY ID_ DESC
+	</select>
+
 	<update id="update" parameterType="com.lc.ibps.components.pv.persistence.entity.ExperimentalConfigPo">
 		UPDATE T_XNYZPZXX SET
-		TENANT_ID_=#{tenantId,jdbcType=VARCHAR},
-		IP_=#{ip,jdbcType=VARCHAR},
-		UPDATE_BY_=#{updateBy,jdbcType=VARCHAR},
-		UPDATE_TIME_=#{updateTime,jdbcType=TIMESTAMP},
-		SHI_FOU_GUO_SHEN_=#{shiFouGuoShen,jdbcType=VARCHAR},
-		DI_DIAN_=#{diDian,jdbcType=VARCHAR},
-		KUAI_ZHAO_=#{kuaiZhao,jdbcType=VARCHAR},
-		TYPE_=#{type,jdbcType=VARCHAR},
-		TARGET_=#{target,jdbcType=VARCHAR},
-		SN_=#{sn,jdbcType=VARCHAR},
-		CONFIG_=#{config,jdbcType=BLOB},
-		ICON_=#{icon,jdbcType=VARCHAR},
-		TARGET_KEY_=#{targetKey,jdbcType=VARCHAR}
+							  TENANT_ID_=#{tenantId,jdbcType=VARCHAR},
+							  IP_=#{ip,jdbcType=VARCHAR},
+							  UPDATE_BY_=#{updateBy,jdbcType=VARCHAR},
+							  UPDATE_TIME_=#{updateTime,jdbcType=TIMESTAMP},
+							  DI_DIAN_=#{diDian,jdbcType=VARCHAR},
+							  TYPE_=#{type,jdbcType=VARCHAR},
+							  TARGET_=#{target,jdbcType=VARCHAR},
+							  SN_=#{sn,jdbcType=VARCHAR},
+							  CONFIG_=#{config,jdbcType=BLOB},
+							  ICON_=#{icon,jdbcType=VARCHAR},
+							  TARGET_KEY_=#{targetKey,jdbcType=VARCHAR}
 		WHERE
-		ID_=#{id}
+			ID_=#{id}
 	</update>
-	
+
 	<delete id="remove" parameterType="java.lang.String">
-		DELETE FROM T_XNYZPZXX 
+		DELETE FROM T_XNYZPZXX
 		WHERE
-		ID_=#{id}
+			ID_=#{id}
 	</delete>
-	
-	
+
+
 </mapper>

+ 4 - 4
ibps-provider-root/modules/provider-business/src/main/resources/com/lc/ibps/pv/persistence/mapping/ExperimentalConfigDetail.map.xml

@@ -15,7 +15,7 @@
 		<result property="methodType" column="METHOD_TYPE_" jdbcType="VARCHAR"/>
 		<result property="sn" column="SN_" jdbcType="VARCHAR"/>
 		<result property="isBasic" column="IS_BASIC" jdbcType="VARCHAR"/>
-		<result property="idDisabled" column="ID_DISABLED_" jdbcType="VARCHAR"/>
+		<result property="isDisabled" column="IS_DISABLED_" jdbcType="VARCHAR"/>
 		<result property="isPublic" column="IS_PUBLIC_" jdbcType="VARCHAR"/>
 		<result property="step" column="STEP_" jdbcType="BLOB"/>
 		<result property="criterion" column="CRITERION_" jdbcType="BLOB"/>
@@ -29,14 +29,14 @@
 	</resultMap>
 	
 	<sql id="columns">
-		ID_,PARENT_ID_,TENANT_ID_,IP_,CREATE_BY_,CREATE_TIME_,UPDATE_BY_,UPDATE_TIME_,METHOD_NAME_,METHOD_TYPE_,SN_,IS_BASIC,ID_DISABLED_,IS_PUBLIC_,STEP_,CRITERION_,REFERENCES_,PARAMS_,FORMULAS_,TEMPLATE_,TEMPLATE_DESC_,CHART_OPTION_,SCOPE_
+		ID_,PARENT_ID_,TENANT_ID_,IP_,CREATE_BY_,CREATE_TIME_,UPDATE_BY_,UPDATE_TIME_,METHOD_NAME_,METHOD_TYPE_,SN_,IS_BASIC,IS_DISABLED_,IS_PUBLIC_,STEP_,CRITERION_,REFERENCES_,PARAMS_,FORMULAS_,TEMPLATE_,TEMPLATE_DESC_,CHART_OPTION_,SCOPE_
 	</sql>
 	
 	<insert id="create" parameterType="com.lc.ibps.components.pv.persistence.entity.ExperimentalConfigDetailPo">
 		INSERT INTO T_XNYZPZXQ
 		(<include refid="columns"/>)
 		VALUES 
-		(#{id,jdbcType=VARCHAR}, #{parentId,jdbcType=VARCHAR}, #{tenantId,jdbcType=VARCHAR}, #{ip,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{methodName,jdbcType=VARCHAR}, #{methodType,jdbcType=VARCHAR}, #{sn,jdbcType=VARCHAR}, #{isBasic,jdbcType=VARCHAR}, #{idDisabled,jdbcType=VARCHAR}, #{isPublic,jdbcType=VARCHAR}, #{step,jdbcType=BLOB}, #{criterion,jdbcType=BLOB}, #{references,jdbcType=BLOB}, #{params,jdbcType=BLOB}, #{formulas,jdbcType=BLOB}, #{template,jdbcType=BLOB}, #{templateDesc,jdbcType=BLOB}, #{chartOption,jdbcType=BLOB}, #{scope,jdbcType=VARCHAR})
+		(#{id,jdbcType=VARCHAR}, #{parentId,jdbcType=VARCHAR}, #{tenantId,jdbcType=VARCHAR}, #{ip,jdbcType=VARCHAR}, #{createBy,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateBy,jdbcType=VARCHAR}, #{updateTime,jdbcType=TIMESTAMP}, #{methodName,jdbcType=VARCHAR}, #{methodType,jdbcType=VARCHAR}, #{sn,jdbcType=VARCHAR}, #{isBasic,jdbcType=VARCHAR}, #{isDisabled,jdbcType=VARCHAR}, #{isPublic,jdbcType=VARCHAR}, #{step,jdbcType=BLOB}, #{criterion,jdbcType=BLOB}, #{references,jdbcType=BLOB}, #{params,jdbcType=BLOB}, #{formulas,jdbcType=BLOB}, #{template,jdbcType=BLOB}, #{templateDesc,jdbcType=BLOB}, #{chartOption,jdbcType=BLOB}, #{scope,jdbcType=VARCHAR})
 	</insert>
 	
 	<select id="get" parameterType="java.lang.String" resultMap="ExperimentalConfigDetailPo">
@@ -89,7 +89,7 @@
 		METHOD_TYPE_=#{methodType,jdbcType=VARCHAR},
 		SN_=#{sn,jdbcType=VARCHAR},
 		IS_BASIC=#{isBasic,jdbcType=VARCHAR},
-		ID_DISABLED_=#{idDisabled,jdbcType=VARCHAR},
+		IS_DISABLED_=#{isDisabled,jdbcType=VARCHAR},
 		IS_PUBLIC_=#{isPublic,jdbcType=VARCHAR},
 		STEP_=#{step,jdbcType=BLOB},
 		CRITERION_=#{criterion,jdbcType=BLOB},

+ 5 - 21
ibps-provider-root/modules/provider-business/src/main/resources/pv/report/precisionEP15A2.ftl

@@ -1,23 +1,7 @@
-结果判读
+<h3>结果判读</h3>
+<p>
+与厂家声明的标准差或 CV 比较。如果测得的SDl 或 CV 小于厂家声明的实验室标准差则通过验证。若测得的室内标准差大于厂家声明的实验室标准差则应先计算 T 值(程序计算参数,即有效自由度),再通过 T 值来计算出“验证值”,验证厂家提供的精密度声明的上限。如果 SD 低于这一验证值,则已证实满足厂家的声明要求。
 
-① 与厂家声明的标准差或 CV 比较。如果测得的
 
-SDl 或 CV 小于厂家声明的实验室标准差则通过验
-
-证。若测得的室内标准差大于厂家声明的实验室标
-
-准差则应先计算 T 值(程序计算参数,即有效自由
-
-度),再通过 T 值来计算出“验证值”,验证厂家提供
-
-的精密度声明的上限。如果 SD 低于这一验证值,
-
-则已证实满足厂家的声明要求。
-
-② 与 CLIA’ 88 文件推荐的允许总误差(total allowable error,TEa)比
-
-较。得到的 CV 或标准差与 TEa 进行比较。a. 批内
-
-精密度或标准差应≤TEa 的 1/4。b. 批间精密度或
-
-标准差应≤TEa 的 1/3。±
+与室间质量评价文件推荐的允许总误差(total allowable error,TEa)比较。得到的 CV 或标准差与 TEa 进行比较。a. 批内精密度或标准差应≤TEa 的 1/4。b. 批间精密度或标准差应≤TEa 的 1/3。±
+</p>