wangliang 4 tahun lalu
induk
melakukan
2be5bec49b

+ 1 - 1
teachcloud-report-business/src/main/java/com/qmth/teachcloud/report/business/bean/dto/excel/TAExamCourseDto.java

@@ -166,7 +166,7 @@ public class TAExamCourseDto implements Serializable {
 
     public String getPastRealityRate() {
         if (Objects.nonNull(pastRealityRate)) {
-            return pastRealityRate + "(" + pastRealityCount + ")";
+            return new BigDecimal(pastRealityRate).setScale(SystemConstant.FINAL_SCALE, BigDecimal.ROUND_HALF_UP) + "(" + pastRealityCount + ")";
         } else {
             return pastRealityRate;
         }

+ 73 - 35
teachcloud-report-business/src/main/java/com/qmth/teachcloud/report/business/bean/dto/excel/TAExamCourseExportDto.java

@@ -38,31 +38,31 @@ public class TAExamCourseExportDto implements Serializable {
     @ExcelProperty(name = "缺考", width = 30, index = 7)
     private Integer absentCount;
 
-    @ExcelProperty(name = "总体平均分(赋分前)", width = 50, index = 8)
+    @ExcelProperty(name = "总体平均分-赋分前", width = 50, index = 8)
     private BigDecimal avgScoreBefore;
 
-    @ExcelProperty(name = "总体不及格率(赋分前)", width = 50, index = 9)
+    @ExcelProperty(name = "总体不及格率(人数)-赋分前", width = 50, index = 9)
     private String notPassRateBefore;
 
-    @ExcelProperty(name = "应届平均分(赋分前)", width = 50, index = 10)
+    @ExcelProperty(name = "应届平均分-赋分前", width = 50, index = 10)
     private BigDecimal currentAvgScoreBefore;
 
-    @ExcelProperty(name = "应届不及格率(赋分前)", width = 50, index = 11)
+    @ExcelProperty(name = "应届不及格率(人数)-赋分前", width = 50, index = 11)
     private String currentNotPassRateBefore;
 
     @ExcelProperty(name = "赋分系数", width = 30, index = 12)
     private BigDecimal coefficient;
 
-    @ExcelProperty(name = "总体平均分(赋分后)", width = 50, index = 13)
+    @ExcelProperty(name = "总体平均分-赋分后", width = 50, index = 13)
     private BigDecimal avgScoreAfter;
 
-    @ExcelProperty(name = "总体不及格率(赋分后)", width = 50, index = 14)
+    @ExcelProperty(name = "总体不及格率(人数)-赋分后", width = 50, index = 14)
     private String notPassRateAfter;
 
-    @ExcelProperty(name = "应届平均分(赋分后)", width = 50, index = 15)
+    @ExcelProperty(name = "应届平均分-赋分后", width = 50, index = 15)
     private BigDecimal currentAvgScoreAfter;
 
-    @ExcelProperty(name = "应届不及格率(赋分后)", width = 50, index = 16)
+    @ExcelProperty(name = "应届不及格率(人数)-赋分后", width = 50, index = 16)
     private String currentNotPassRateAfter;
 
     @ApiModelProperty(value = "科目编码")
@@ -74,37 +74,27 @@ public class TAExamCourseExportDto implements Serializable {
     @ApiModelProperty(value = "应届实际考试人数")
     private Integer currentRealityCount;
 
-    @ApiModelProperty(value = "不通过人数")
-    private Integer notPassCount;
-
-    @ApiModelProperty(value = "应届不通过人数")
-    private Integer currentNotPassCount;
-
     @ApiModelProperty(value = "往届实际考试人数")
     private Integer pastRealityCount;
 
-    public Integer getPastRealityCount() {
-        return pastRealityCount;
-    }
+    @ApiModelProperty(value = "不通过人数(赋分前)")
+    private Integer notPassCountBefore;
 
-    public void setPastRealityCount(Integer pastRealityCount) {
-        this.pastRealityCount = pastRealityCount;
-    }
+    @ApiModelProperty(value = "应届不通过人数(赋分前)")
+    private Integer currentNotPassCountBefore;
 
-    public Integer getNotPassCount() {
-        return notPassCount;
-    }
+    @ApiModelProperty(value = "不通过人数(赋分后)")
+    private Integer notPassCountAfter;
 
-    public void setNotPassCount(Integer notPassCount) {
-        this.notPassCount = notPassCount;
-    }
+    @ApiModelProperty(value = "应届不通过人数(赋分后)")
+    private Integer currentNotPassCountAfter;
 
-    public Integer getCurrentNotPassCount() {
-        return currentNotPassCount;
+    public Integer getPastRealityCount() {
+        return pastRealityCount;
     }
 
-    public void setCurrentNotPassCount(Integer currentNotPassCount) {
-        this.currentNotPassCount = currentNotPassCount;
+    public void setPastRealityCount(Integer pastRealityCount) {
+        this.pastRealityCount = pastRealityCount;
     }
 
     public Integer getCurrentRealityCount() {
@@ -181,7 +171,7 @@ public class TAExamCourseExportDto implements Serializable {
 
     public String getPastRealityRate() {
         if (Objects.nonNull(pastRealityRate)) {
-            return pastRealityRate + "(" + pastRealityCount + ")";
+            return new BigDecimal(pastRealityRate).setScale(SystemConstant.FINAL_SCALE, BigDecimal.ROUND_HALF_UP) + "(" + pastRealityCount + ")";
         } else {
             return pastRealityRate;
         }
@@ -212,7 +202,11 @@ public class TAExamCourseExportDto implements Serializable {
     }
 
     public String getNotPassRateBefore() {
-        return notPassRateBefore;
+        if (Objects.nonNull(notPassRateBefore)) {
+            return new BigDecimal(notPassRateBefore).setScale(SystemConstant.FINAL_SCALE, BigDecimal.ROUND_HALF_UP) + "(" + notPassCountBefore + ")";
+        } else {
+            return notPassRateBefore;
+        }
     }
 
     public void setNotPassRateBefore(String notPassRateBefore) {
@@ -232,7 +226,11 @@ public class TAExamCourseExportDto implements Serializable {
     }
 
     public String getCurrentNotPassRateBefore() {
-        return currentNotPassRateBefore;
+        if (Objects.nonNull(currentNotPassRateBefore)) {
+            return new BigDecimal(currentNotPassRateBefore).setScale(SystemConstant.FINAL_SCALE, BigDecimal.ROUND_HALF_UP) + "(" + currentNotPassCountBefore + ")";
+        } else {
+            return currentNotPassRateBefore;
+        }
     }
 
     public void setCurrentNotPassRateBefore(String currentNotPassRateBefore) {
@@ -264,7 +262,11 @@ public class TAExamCourseExportDto implements Serializable {
     }
 
     public String getNotPassRateAfter() {
-        return notPassRateAfter;
+        if (Objects.nonNull(notPassRateAfter)) {
+            return new BigDecimal(notPassRateAfter).setScale(SystemConstant.FINAL_SCALE, BigDecimal.ROUND_HALF_UP) + "(" + notPassCountAfter + ")";
+        } else {
+            return notPassRateAfter;
+        }
     }
 
     public void setNotPassRateAfter(String notPassRateAfter) {
@@ -284,10 +286,46 @@ public class TAExamCourseExportDto implements Serializable {
     }
 
     public String getCurrentNotPassRateAfter() {
-        return currentNotPassRateAfter;
+        if (Objects.nonNull(currentNotPassRateAfter)) {
+            return new BigDecimal(currentNotPassRateAfter).setScale(SystemConstant.FINAL_SCALE, BigDecimal.ROUND_HALF_UP) + "(" + currentNotPassCountAfter + ")";
+        } else {
+            return currentNotPassRateAfter;
+        }
     }
 
     public void setCurrentNotPassRateAfter(String currentNotPassRateAfter) {
         this.currentNotPassRateAfter = currentNotPassRateAfter;
     }
+
+    public Integer getNotPassCountBefore() {
+        return notPassCountBefore;
+    }
+
+    public void setNotPassCountBefore(Integer notPassCountBefore) {
+        this.notPassCountBefore = notPassCountBefore;
+    }
+
+    public Integer getCurrentNotPassCountBefore() {
+        return currentNotPassCountBefore;
+    }
+
+    public void setCurrentNotPassCountBefore(Integer currentNotPassCountBefore) {
+        this.currentNotPassCountBefore = currentNotPassCountBefore;
+    }
+
+    public Integer getNotPassCountAfter() {
+        return notPassCountAfter;
+    }
+
+    public void setNotPassCountAfter(Integer notPassCountAfter) {
+        this.notPassCountAfter = notPassCountAfter;
+    }
+
+    public Integer getCurrentNotPassCountAfter() {
+        return currentNotPassCountAfter;
+    }
+
+    public void setCurrentNotPassCountAfter(Integer currentNotPassCountAfter) {
+        this.currentNotPassCountAfter = currentNotPassCountAfter;
+    }
 }

+ 44 - 0
teachcloud-report-business/src/main/java/com/qmth/teachcloud/report/business/bean/result/TAExamCourseResult.java

@@ -44,12 +44,56 @@ public class TAExamCourseResult extends TAExamCourse implements Serializable {
     @ApiModelProperty(value = "应届不及格率-赋分后")
     private BigDecimal currentNotPassRateAfter;
 
+    @ApiModelProperty(value = "不通过人数(赋分前)")
+    private Integer notPassCountBefore;
+
+    @ApiModelProperty(value = "应届不通过人数(赋分前)")
+    private Integer currentNotPassCountBefore;
+
+    @ApiModelProperty(value = "不通过人数(赋分后)")
+    private Integer notPassCountAfter;
+
+    @ApiModelProperty(value = "应届不通过人数(赋分后)")
+    private Integer currentNotPassCountAfter;
+
     @ApiModelProperty(value = "发布状态(UN_COMPUTE:未计算、UN_PUBLISH:未发布、PUBLISH:已发布)")
     private PublishStatusEnum status;
 
     @ApiModelProperty(value = "发布状态(UN_COMPUTE:未计算、UN_PUBLISH:未发布、PUBLISH:已发布)")
     private String publishStatus;
 
+    public Integer getNotPassCountBefore() {
+        return notPassCountBefore;
+    }
+
+    public void setNotPassCountBefore(Integer notPassCountBefore) {
+        this.notPassCountBefore = notPassCountBefore;
+    }
+
+    public Integer getCurrentNotPassCountBefore() {
+        return currentNotPassCountBefore;
+    }
+
+    public void setCurrentNotPassCountBefore(Integer currentNotPassCountBefore) {
+        this.currentNotPassCountBefore = currentNotPassCountBefore;
+    }
+
+    public Integer getNotPassCountAfter() {
+        return notPassCountAfter;
+    }
+
+    public void setNotPassCountAfter(Integer notPassCountAfter) {
+        this.notPassCountAfter = notPassCountAfter;
+    }
+
+    public Integer getCurrentNotPassCountAfter() {
+        return currentNotPassCountAfter;
+    }
+
+    public void setCurrentNotPassCountAfter(Integer currentNotPassCountAfter) {
+        this.currentNotPassCountAfter = currentNotPassCountAfter;
+    }
+
     public PublishStatusEnum getStatus() {
         return status;
     }

+ 5 - 1
teachcloud-report-business/src/main/resources/mapper/TAExamCourseMapper.xml

@@ -26,7 +26,11 @@
             (1 - taec.pass_rate) as notPassRateAfter,
             taec.current_avg_score as currentAvgScoreAfter,
             (1 - taec.current_pass_rate) as currentNotPassRateAfter,
-            taec.coefficient
+            taec.coefficient,
+            (taec.reality_count - taec.pass_count) as notPassCountBefore,
+            (taec.current_reality_count - taec.current_pass_count) as currentNotPassCountBefore,
+            (taec.current_reality_count - taec.current_pass_count) as notPassCountAfter,
+            (taec.current_reality_count - taec.current_pass_count) as currentNotPassCountAfter
     </sql>
 
     <sql id="commonCondition">