Эх сурвалжийг харах

课程专业达成度雷达报表

wangliang 1 жил өмнө
parent
commit
1dd0f7ab0f
18 өөрчлөгдсөн 188 нэмэгдсэн , 194 устгасан
  1. 8 4
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/bean/dto/report/ObeCourseRequirementDto.java
  2. 1 4
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/bean/dto/report/ObeRequirementDto.java
  3. 1 1
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/bean/dto/report/ObeSubRequirementsDto.java
  4. 2 2
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/entity/TCUsualScore.java
  5. 20 20
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TCFinalScoreService.java
  6. 12 12
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TCPaperStructService.java
  7. 6 6
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TCUsualScoreService.java
  8. 12 12
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TRBasicInfoService.java
  9. 2 2
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TRExamStudentService.java
  10. 34 34
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TCFinalScoreServiceImpl.java
  11. 30 30
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TCPaperStructServiceImpl.java
  12. 11 11
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TCUsualScoreServiceImpl.java
  13. 30 30
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TRBasicInfoServiceImpl.java
  14. 3 3
      distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TRExamStudentServiceImpl.java
  15. 8 8
      distributed-print-business/src/main/resources/mapper/TCFinalScoreMapper.xml
  16. 3 3
      distributed-print-business/src/main/resources/mapper/TCUsualScoreMapper.xml
  17. 1 10
      distributed-print/src/main/java/com/qmth/distributed/print/api/ObeReportController.java
  18. 4 2
      teachcloud-common/src/main/java/com/qmth/teachcloud/common/contant/SystemConstant.java

+ 8 - 4
distributed-print-business/src/main/java/com/qmth/distributed/print/business/bean/dto/report/ObeCourseRequirementDto.java

@@ -2,7 +2,6 @@ package com.qmth.distributed.print.business.bean.dto.report;
 
 import com.fasterxml.jackson.annotation.JsonInclude;
 import com.qmth.distributed.print.business.bean.dto.obe.CourseRequirementMatrixDto;
-import com.qmth.distributed.print.business.bean.dto.obe.MatrixRequirementDto;
 import io.swagger.annotations.ApiModelProperty;
 
 import java.io.Serializable;
@@ -28,18 +27,23 @@ public class ObeCourseRequirementDto implements Serializable {
     @ApiModelProperty(value = "课程毕业指标达成值")
     private BigDecimal matrixDegree;
 
-    @ApiModelProperty(value = "课程毕业指标达成值")
+    @ApiModelProperty(value = "课程毕业指标集合")
     private List<ObeRequirementDto> obeRequirements;
 
-    public ObeCourseRequirementDto(){
+    public ObeCourseRequirementDto() {
 
     }
 
-    public ObeCourseRequirementDto(CourseRequirementMatrixDto courseRequirementMatrixDto){
+    public ObeCourseRequirementDto(CourseRequirementMatrixDto courseRequirementMatrixDto) {
         this.courseCode = courseRequirementMatrixDto.getCourseCode();
         this.courseName = courseRequirementMatrixDto.getCourseName();
     }
 
+    public void updateInfo() {
+        this.courseCode = null;
+        this.courseName = null;
+    }
+
     public String getCourseCode() {
         return courseCode;
     }

+ 1 - 4
distributed-print-business/src/main/java/com/qmth/distributed/print/business/bean/dto/report/ObeRequirementDto.java

@@ -2,9 +2,6 @@ package com.qmth.distributed.print.business.bean.dto.report;
 
 import com.fasterxml.jackson.annotation.JsonInclude;
 import com.qmth.distributed.print.business.bean.dto.obe.MatrixRequirementDto;
-import com.qmth.distributed.print.business.bean.dto.obe.MatrixSubRequirementDto;
-import com.qmth.distributed.print.business.entity.BasicProfessional;
-import com.qmth.teachcloud.common.base.BaseEntity;
 import io.swagger.annotations.ApiModelProperty;
 
 import java.io.Serializable;
@@ -22,7 +19,7 @@ import java.util.List;
 public class ObeRequirementDto extends MatrixRequirementDto implements Serializable {
 
     @ApiModelProperty(value = "毕业指标达成值")
-    private BigDecimal matrixDegree;
+    private BigDecimal matrixDegree = new BigDecimal(0);
 
     @ApiModelProperty(value = "毕业指标点集合")
     private List<ObeSubRequirementsDto> obeSubRequirements;

+ 1 - 1
distributed-print-business/src/main/java/com/qmth/distributed/print/business/bean/dto/report/ObeSubRequirementsDto.java

@@ -36,7 +36,7 @@ public class ObeSubRequirementsDto extends CourseTargetWebDto {
     private String content;
 
     @ApiModelProperty(value = "毕业指标点达成值")
-    private BigDecimal matrixDegree;
+    private BigDecimal matrixDegree = new BigDecimal(0);
 
     public ObeSubRequirementsDto() {
 

+ 2 - 2
distributed-print-business/src/main/java/com/qmth/distributed/print/business/entity/TCUsualScore.java

@@ -62,13 +62,13 @@ public class TCUsualScore extends BaseEntity implements Serializable {
 
     }
 
-    public TCUsualScore(Long examId, String courseCode, String courseName, String paperNumber, Long teachCourseId, Long userId) {
+    public TCUsualScore(Long examId, String courseCode, String courseName, String paperNumber, Long obeCourseOutlineId, Long userId) {
         insertInfo(userId);
         this.examId = examId;
         this.courseCode = courseCode;
         this.courseName = courseName;
         this.paperNumber = paperNumber;
-        this.teachCourseId = teachCourseId;
+        this.teachCourseId = obeCourseOutlineId;
         this.enable = true;
     }
 

+ 20 - 20
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TCFinalScoreService.java

@@ -28,11 +28,11 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
-    public Map<String, String> finalScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException;
+    public Map<String, String> finalScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException;
 
     /**
      * 期末成绩列表(分页)
@@ -41,10 +41,10 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public IPage<TCFinalScore> finalScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public IPage<TCFinalScore> finalScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 查找期末成绩分数图
@@ -52,10 +52,10 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public FinalScoreDto finalScoreScoreOverView(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public FinalScoreDto finalScoreScoreOverView(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 查找期末成绩分数区间
@@ -63,12 +63,12 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @param start
      * @param end
      * @return
      */
-    public int getCountByScoreRange(Long examId, String courseCode, String paperNumber, Long teachCourseId, Double start, Double end);
+    public int getCountByScoreRange(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId, Double start, Double end);
 
     /**
      * 查找考生成绩
@@ -76,10 +76,10 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public List<FinalScoreResult> examStudentOverview(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public List<FinalScoreResult> examStudentOverview(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 同步期末成绩
@@ -87,11 +87,11 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
-    public Map<String, String> finalScoreSync(Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException;
+    public Map<String, String> finalScoreSync(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException;
 
     /**
      * 根据考试id/课程编码/试卷编码删除数据
@@ -99,10 +99,10 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 根据考试id/课程编码/试卷编码查询数据库数据
@@ -110,10 +110,10 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public List<TCFinalScore> queryFinalScore(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public List<TCFinalScore> queryFinalScore(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 获取期末考试同步锁
@@ -121,9 +121,9 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      */
-    public void getFinalScoreSyncLock(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public void getFinalScoreSyncLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 获取期末考试导入锁
@@ -131,7 +131,7 @@ public interface TCFinalScoreService extends IService<TCFinalScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      */
-    public void getFinalScoreImportLock(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public void getFinalScoreImportLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 }

+ 12 - 12
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TCPaperStructService.java

@@ -23,10 +23,10 @@ public interface TCPaperStructService extends IService<TCPaperStruct> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 导入期末成绩-试卷结构excel
@@ -35,11 +35,11 @@ public interface TCPaperStructService extends IService<TCPaperStruct> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
-    public Map<String, String> paperStructExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException;
+    public Map<String, String> paperStructExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException;
 
     /**
      * 同步试卷结构
@@ -47,11 +47,11 @@ public interface TCPaperStructService extends IService<TCPaperStruct> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
-    public Map<String, String> paperStructSync(Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException;
+    public Map<String, String> paperStructSync(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException;
 
     /**
      * 根据考试id/科目编辑/试卷编码查询数据
@@ -59,10 +59,10 @@ public interface TCPaperStructService extends IService<TCPaperStruct> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public TCPaperStruct queryPaperStruct(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public TCPaperStruct queryPaperStruct(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 获取试卷结构同步锁
@@ -70,9 +70,9 @@ public interface TCPaperStructService extends IService<TCPaperStruct> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      */
-    public void getPaperStructSyncLock(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public void getPaperStructSyncLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 获取试卷结构导入锁
@@ -80,7 +80,7 @@ public interface TCPaperStructService extends IService<TCPaperStruct> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      */
-    public void getPaperStructImportLock(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public void getPaperStructImportLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 }

+ 6 - 6
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TCUsualScoreService.java

@@ -26,11 +26,11 @@ public interface TCUsualScoreService extends IService<TCUsualScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
-    public Map<String, String> usualScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException;
+    public Map<String, String> usualScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException;
 
     /**
      * 平时成绩列表(分页)
@@ -39,10 +39,10 @@ public interface TCUsualScoreService extends IService<TCUsualScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public IPage<TCUsualScore> usualScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public IPage<TCUsualScore> usualScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 根据考试id/课程编码/试卷编码查询数据库数据
@@ -50,8 +50,8 @@ public interface TCUsualScoreService extends IService<TCUsualScore> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public List<TCUsualScore> queryUsualScore(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public List<TCUsualScore> queryUsualScore(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 }

+ 12 - 12
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TRBasicInfoService.java

@@ -31,10 +31,10 @@ public interface TRBasicInfoService extends IService<TRBasicInfo> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public TRBasicInfo queryBasicInfo(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public TRBasicInfo queryBasicInfo(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 获取课程目标考核分布-分数图
@@ -71,10 +71,10 @@ public interface TRBasicInfoService extends IService<TRBasicInfo> {
      * @param markPaper
      * @param userId
      * @param obeCourseWeightResult
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public TRBasicInfo getReportView(TRBasicInfo trBasicInfo, MarkPaper markPaper, Long userId, ObeCourseWeightResult obeCourseWeightResult, Long teachCourseId);
+    public TRBasicInfo getReportView(TRBasicInfo trBasicInfo, MarkPaper markPaper, Long userId, ObeCourseWeightResult obeCourseWeightResult, Long obeCourseOutlineId);
 
     /**
      * 构建word动态表格1-课程目标与毕业要求指标点的对应关系
@@ -123,26 +123,26 @@ public interface TRBasicInfoService extends IService<TRBasicInfo> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 
     /**
      * 查找课程评价值
      *
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public ObeCourseWeightResult findCourseWeightResultRmi(Long teachCourseId);
+    public ObeCourseWeightResult findCourseWeightResultRmi(Long obeCourseOutlineId);
 
     /**
      * 查找课程评价值
      *
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public List<CourseWeightDto> findCourseWeightDtoRmi(Long teachCourseId);
+    public List<CourseWeightDto> findCourseWeightDtoRmi(Long obeCourseOutlineId);
 
     /**
      * 清除报告数据
@@ -150,8 +150,8 @@ public interface TRBasicInfoService extends IService<TRBasicInfo> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @param clearDimension
      */
-    public void clearReportData(Long examId, String courseCode, String paperNumber, Long teachCourseId, boolean clearDimension);
+    public void clearReportData(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId, boolean clearDimension);
 }

+ 2 - 2
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/TRExamStudentService.java

@@ -41,8 +41,8 @@ public interface TRExamStudentService extends IService<TRExamStudent> {
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId);
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId);
 }

+ 34 - 34
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TCFinalScoreServiceImpl.java

@@ -86,13 +86,13 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
     @Override
     @Transactional
-    public Map<String, String> finalScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException {
+    public Map<String, String> finalScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException {
         log.debug("导入Excel开始...");
         long start = System.currentTimeMillis();
         Map<String, String> messageMap = new LinkedHashMap<>();
@@ -129,7 +129,7 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
                         }
                         boolean error = false;
                         List<TCFinalScoreDto> tcFinalScoreDtoList = new ArrayList<>();
-                        TCFinalScore tcFinalScore = new TCFinalScore(examId, courseCode, markPaper.getCourseName(), paperNumber, teachCourseId, SourceEnum.EXCEL_IMPORT, sysUser.getId());
+                        TCFinalScore tcFinalScore = new TCFinalScore(examId, courseCode, markPaper.getCourseName(), paperNumber, obeCourseOutlineId, SourceEnum.EXCEL_IMPORT, sysUser.getId());
                         BigDecimal score = new BigDecimal(0);
                         for (int j = 0; j < strs.length; j++) {
                             if (Objects.isNull(strs[j]) || Objects.equals(strs[j].trim(), "")) {
@@ -176,11 +176,11 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
                 }
                 if (!CollectionUtils.isEmpty(tcFinalScoreList)) {
                     successData.add("共导入").add(tcFinalScoreList.size() + "").add("条数据");
-                    List<TCFinalScore> tcFinalScoreDbSourceList = tcFinalScoreService.queryFinalScore(examId, courseCode, paperNumber, teachCourseId);
+                    List<TCFinalScore> tcFinalScoreDbSourceList = tcFinalScoreService.queryFinalScore(examId, courseCode, paperNumber, obeCourseOutlineId);
                     if (CollectionUtils.isEmpty(tcFinalScoreDbSourceList) || !CollectionUtils.isEqualCollection(tcFinalScoreDbSourceList, tcFinalScoreList)) {
                         tcFinalScoreService.removeByIds(tcFinalScoreDbSourceList.stream().map(s -> s.getId()).collect(Collectors.toList()));
                         tcFinalScoreService.saveBatch(tcFinalScoreList);
-                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, true);
+                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, obeCourseOutlineId, true);
                     }
                 }
             }
@@ -211,12 +211,12 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public IPage<TCFinalScore> finalScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        return this.baseMapper.finalScoreList(iPage, examId, courseCode, paperNumber, teachCourseId);
+    public IPage<TCFinalScore> finalScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        return this.baseMapper.finalScoreList(iPage, examId, courseCode, paperNumber, obeCourseOutlineId);
     }
 
     /**
@@ -225,12 +225,12 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public FinalScoreDto finalScoreScoreOverView(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        return this.baseMapper.finalScoreScoreOverView(examId, courseCode, paperNumber, teachCourseId);
+    public FinalScoreDto finalScoreScoreOverView(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        return this.baseMapper.finalScoreScoreOverView(examId, courseCode, paperNumber, obeCourseOutlineId);
     }
 
     /**
@@ -239,14 +239,14 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @param start
      * @param end
      * @return
      */
     @Override
-    public int getCountByScoreRange(Long examId, String courseCode, String paperNumber, Long teachCourseId, Double start, Double end) {
-        return this.baseMapper.getCountByScoreRange(examId, courseCode, paperNumber, teachCourseId, start, end);
+    public int getCountByScoreRange(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId, Double start, Double end) {
+        return this.baseMapper.getCountByScoreRange(examId, courseCode, paperNumber, obeCourseOutlineId, start, end);
     }
 
     /**
@@ -255,12 +255,12 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public List<FinalScoreResult> examStudentOverview(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        return this.baseMapper.examStudentOverview(examId, courseCode, paperNumber, teachCourseId);
+    public List<FinalScoreResult> examStudentOverview(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        return this.baseMapper.examStudentOverview(examId, courseCode, paperNumber, obeCourseOutlineId);
     }
 
     /**
@@ -269,13 +269,13 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
     @Override
     @Transactional
-    public Map<String, String> finalScoreSync(Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException {
+    public Map<String, String> finalScoreSync(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException {
         Map<String, String> messageMap = new LinkedHashMap<>();
         try {
             SysUser sysUser = (SysUser) ServletUtil.getRequestUser();
@@ -296,18 +296,18 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
                                 paperStructDimensionResultList.add(new PaperStructDimensionResult(scoreItem.getMainNumber(), scoreItem.getSubNumber(), paperNumber, scoreItem.getTotalScore()));
                             }
                         }
-                        tcFinalScoreList.add(new TCFinalScore(markStudentScoreVo, JacksonUtil.parseJson(tcFinalScoreDtoList), SourceEnum.SYNC, sysUser.getId(), teachCourseId));
+                        tcFinalScoreList.add(new TCFinalScore(markStudentScoreVo, JacksonUtil.parseJson(tcFinalScoreDtoList), SourceEnum.SYNC, sysUser.getId(), obeCourseOutlineId));
                     }
                 }
                 if (!CollectionUtils.isEmpty(tcFinalScoreList) && !CollectionUtils.isEmpty(paperStructDimensionResultList)) {
                     successData.add("共同步").add(tcFinalScoreList.size() + "").add("条数据");
-                    List<TCFinalScore> tcFinalScoreDbSourceList = tcFinalScoreService.queryFinalScore(examId, courseCode, paperNumber, teachCourseId);
+                    List<TCFinalScore> tcFinalScoreDbSourceList = tcFinalScoreService.queryFinalScore(examId, courseCode, paperNumber, obeCourseOutlineId);
                     if (CollectionUtils.isEmpty(tcFinalScoreDbSourceList) || !CollectionUtils.isEqualCollection(tcFinalScoreDbSourceList, tcFinalScoreList)) {
                         tcFinalScoreService.removeByIds(tcFinalScoreDbSourceList.stream().map(s -> s.getId()).collect(Collectors.toList()));
                         tcFinalScoreService.saveBatch(tcFinalScoreList);
-                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, true);
+                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, obeCourseOutlineId, true);
                     }
-                    TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(examId, courseCode, null, teachCourseId);
+                    TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(examId, courseCode, null, obeCourseOutlineId);
                     if (Objects.nonNull(tcPaperStruct)) {
                         tcPaperStruct.setPaperNumber(paperNumber);
                         tcPaperStruct.setPaperStruct(JacksonUtil.parseJson(paperStructDimensionResultList));
@@ -316,7 +316,7 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
                     } else {
                         BasicCourse basicCourse = basicCourseService.getByCode(courseCode);
                         Objects.requireNonNull(basicCourse, "未找到基础课程信息");
-                        tcPaperStruct = new TCPaperStruct(examId, courseCode, basicCourse.getName(), paperNumber, teachCourseId, JacksonUtil.parseJson(paperStructDimensionResultList), sysUser.getId());
+                        tcPaperStruct = new TCPaperStruct(examId, courseCode, basicCourse.getName(), paperNumber, obeCourseOutlineId, JacksonUtil.parseJson(paperStructDimensionResultList), sysUser.getId());
                     }
                     tcPaperStructService.saveOrUpdate(tcPaperStruct);
                 }
@@ -344,18 +344,18 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
     @Transactional
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TCFinalScore> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TCFinalScore::getExamId, examId).eq(TCFinalScore::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TCFinalScore::getPaperNumber, paperNumber).or().isNull(TCFinalScore::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TCFinalScore::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TCFinalScore::getTeachCourseId, obeCourseOutlineId);
         return tcFinalScoreService.remove(queryWrapper);
     }
 
@@ -365,17 +365,17 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public List<TCFinalScore> queryFinalScore(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public List<TCFinalScore> queryFinalScore(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TCFinalScore> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TCFinalScore::getExamId, examId).eq(TCFinalScore::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TCFinalScore::getPaperNumber, paperNumber).or().isNull(TCFinalScore::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TCFinalScore::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TCFinalScore::getTeachCourseId, obeCourseOutlineId);
         return tcFinalScoreService.list(queryWrapper);
     }
 
@@ -387,8 +387,8 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param paperNumber
      */
     @Override
-    public void getFinalScoreSyncLock(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        String lockKey = SystemConstant.REDIS_FINAL_SCORE_DATA_FLOW_PREFIX + SystemConstant.SYNC + examId + "_" + courseCode + "_" + paperNumber + "_" + teachCourseId;
+    public void getFinalScoreSyncLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        String lockKey = SystemConstant.REDIS_FINAL_SCORE_DATA_FLOW_PREFIX + SystemConstant.SYNC + examId + "_" + courseCode + "_" + paperNumber + "_" + obeCourseOutlineId;
         Object o = redisUtil.get(lockKey);
         if (Objects.nonNull(o)) {
             throw ExceptionResultEnum.ERROR.exception("正在同步期末成绩数据,请稍候再试!");
@@ -403,8 +403,8 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
      * @param paperNumber
      */
     @Override
-    public void getFinalScoreImportLock(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        String lockKey = SystemConstant.REDIS_FINAL_SCORE_DATA_FLOW_PREFIX + SystemConstant.IMPORT + examId + "_" + courseCode + "_" + paperNumber + "_" + teachCourseId;
+    public void getFinalScoreImportLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        String lockKey = SystemConstant.REDIS_FINAL_SCORE_DATA_FLOW_PREFIX + SystemConstant.IMPORT + examId + "_" + courseCode + "_" + paperNumber + "_" + obeCourseOutlineId;
         Object o = redisUtil.get(lockKey);
         if (Objects.nonNull(o)) {
             throw ExceptionResultEnum.ERROR.exception("正在导入期末成绩数据,请稍候再试!");

+ 30 - 30
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TCPaperStructServiceImpl.java

@@ -73,18 +73,18 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
     @Transactional
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TCPaperStruct> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TCPaperStruct::getExamId, examId).eq(TCPaperStruct::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TCPaperStruct::getPaperNumber, paperNumber).or().isNull(TCPaperStruct::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TCPaperStruct::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TCPaperStruct::getTeachCourseId, obeCourseOutlineId);
         return tcPaperStructService.remove(queryWrapper);
     }
 
@@ -95,13 +95,13 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
     @Override
     @Transactional
-    public Map<String, String> paperStructExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException {
+    public Map<String, String> paperStructExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException {
         log.debug("导入Excel开始...");
         long start = System.currentTimeMillis();
         Map<String, String> messageMap = new LinkedHashMap<>();
@@ -160,13 +160,13 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
                 }
                 if (!CollectionUtils.isEmpty(paperStructDtoNewList)) {
                     successData.add("共导入").add(paperStructDtoNewList.size() + "").add("条数据");
-                    TCPaperStruct tcPaperStruct = new TCPaperStruct(examId, courseCode, markPaper.getCourseName(), paperNumber, teachCourseId, JacksonUtil.parseJson(paperStructDtoNewList), totalScore, 60d, sysUser.getId());
-                    TCPaperStruct tcPaperStructDb = tcPaperStructService.queryPaperStruct(examId, courseCode, paperNumber, teachCourseId);
+                    TCPaperStruct tcPaperStruct = new TCPaperStruct(examId, courseCode, markPaper.getCourseName(), paperNumber, obeCourseOutlineId, JacksonUtil.parseJson(paperStructDtoNewList), totalScore, 60d, sysUser.getId());
+                    TCPaperStruct tcPaperStructDb = tcPaperStructService.queryPaperStruct(examId, courseCode, paperNumber, obeCourseOutlineId);
                     if (Objects.nonNull(tcPaperStructDb) && !tcPaperStructDb.equals(tcPaperStruct)) {
-                        tcFinalScoreService.remove(examId, courseCode, paperNumber, teachCourseId);
-                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, true);
+                        tcFinalScoreService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
+                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, obeCourseOutlineId, true);
                     }
-                    tcPaperStructService.remove(examId, courseCode, paperNumber, teachCourseId);
+                    tcPaperStructService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
                     tcPaperStructService.save(tcPaperStruct);
                 }
             }
@@ -197,19 +197,19 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
     @Override
     @Transactional
-    public Map<String, String> paperStructSync(Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException {
+    public Map<String, String> paperStructSync(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException {
         Map<String, String> messageMap = new LinkedHashMap<>();
         try {
             SysUser sysUser = (SysUser) ServletUtil.getRequestUser();
             StringJoiner errorData = new StringJoiner("");
             StringJoiner successData = new StringJoiner("");
-            List<PaperStructDimensionResult> paperStructDimensionResultList = obeCourseTargetService.findTikuPaperStruct(teachCourseId, paperNumber, examId);
+            List<PaperStructDimensionResult> paperStructDimensionResultList = obeCourseTargetService.findTikuPaperStruct(obeCourseOutlineId, paperNumber, examId);
             if (CollectionUtils.isEmpty(paperStructDimensionResultList)) {
                 throw ExceptionResultEnum.ERROR.exception("未查询到题和知识点对应关系请手动关联");
             }
@@ -223,7 +223,7 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
                 paperStructList.add(p.getMainNumber() + "_" + p.getSubNumber() + "_" + p.getScore());
             }
             successData.add("共同步").add(paperStructDimensionResultList.size() + "").add("条数据");
-            TCPaperStruct tcPaperStructDb = tcPaperStructService.queryPaperStruct(examId, courseCode, paperNumber, teachCourseId);
+            TCPaperStruct tcPaperStructDb = tcPaperStructService.queryPaperStruct(examId, courseCode, paperNumber, obeCourseOutlineId);
             TCPaperStruct tcPaperStruct = null;
             if (Objects.nonNull(tcPaperStructDb) && Objects.nonNull(tcPaperStructDb.getPaperStructDimension())) {
                 tcPaperStruct = new TCPaperStruct();
@@ -245,16 +245,16 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
                     Collections.sort(paperStructDbList);
                     Collections.sort(paperStructList);
 
-                    tcFinalScoreService.remove(examId, courseCode, paperNumber, teachCourseId);
-                    trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, false);
+                    tcFinalScoreService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
+                    trBasicInfoService.clearReportData(examId, courseCode, paperNumber, obeCourseOutlineId, false);
                     tcPaperStruct.setPaperStruct(null);
                 }
                 tcPaperStruct.updateInfo(sysUser.getId());
             } else {
-                tcPaperStructService.remove(examId, courseCode, paperNumber, teachCourseId);
+                tcPaperStructService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
                 MarkPaper markPaper = printCommonService.getMarkPaper(examId, courseCode, paperNumber);
-                ObeCourseWeightResult obeCourseWeightResult = trBasicInfoService.findCourseWeightResultRmi(teachCourseId);
-                tcPaperStruct = new TCPaperStruct(examId, courseCode, markPaper.getCourseName(), paperNumber, teachCourseId, JacksonUtil.parseJson(paperStructDimensionResultList), sysUser.getId(), obeCourseWeightResult.getDimensionSign());
+                ObeCourseWeightResult obeCourseWeightResult = trBasicInfoService.findCourseWeightResultRmi(obeCourseOutlineId);
+                tcPaperStruct = new TCPaperStruct(examId, courseCode, markPaper.getCourseName(), paperNumber, obeCourseOutlineId, JacksonUtil.parseJson(paperStructDimensionResultList), sysUser.getId(), obeCourseWeightResult.getDimensionSign());
                 List<MarkQuestion> markQuestionList = markQuestionService.listQuestionByExamIdAndPaperNumberAndPaperType(examId, paperNumber, null);
                 if (CollectionUtils.isEmpty(markQuestionList)) {
                     throw ExceptionResultEnum.ERROR.exception("未找到试卷结构");
@@ -264,8 +264,8 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
                     Collections.sort(paperStructDbList);
                     Collections.sort(paperStructList);
 
-                    tcFinalScoreService.remove(examId, courseCode, paperNumber, teachCourseId);
-                    trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, false);
+                    tcFinalScoreService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
+                    trBasicInfoService.clearReportData(examId, courseCode, paperNumber, obeCourseOutlineId, false);
                 }
             }
             tcPaperStructService.saveOrUpdate(tcPaperStruct);
@@ -292,17 +292,17 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public TCPaperStruct queryPaperStruct(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public TCPaperStruct queryPaperStruct(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TCPaperStruct> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TCPaperStruct::getExamId, examId).eq(TCPaperStruct::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TCPaperStruct::getPaperNumber, paperNumber).or().isNull(TCPaperStruct::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TCPaperStruct::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TCPaperStruct::getTeachCourseId, obeCourseOutlineId);
         return tcPaperStructService.getOne(queryWrapper);
     }
 
@@ -312,11 +312,11 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      */
     @Override
-    public void getPaperStructSyncLock(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        String lockKey = SystemConstant.REDIS_PAPER_STRUCT_FLOW_PREFIX + SystemConstant.SYNC + examId + "_" + courseCode + "_" + paperNumber + "_" + teachCourseId;
+    public void getPaperStructSyncLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        String lockKey = SystemConstant.REDIS_PAPER_STRUCT_FLOW_PREFIX + SystemConstant.SYNC + examId + "_" + courseCode + "_" + paperNumber + "_" + obeCourseOutlineId;
         Object o = redisUtil.get(lockKey);
         if (Objects.nonNull(o)) {
             throw ExceptionResultEnum.ERROR.exception("正在同步试卷蓝图数据,请稍候再试!");
@@ -329,11 +329,11 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      */
     @Override
-    public void getPaperStructImportLock(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        String lockKey = SystemConstant.REDIS_PAPER_STRUCT_FLOW_PREFIX + SystemConstant.IMPORT + examId + "_" + courseCode + "_" + paperNumber + "_" + teachCourseId;
+    public void getPaperStructImportLock(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        String lockKey = SystemConstant.REDIS_PAPER_STRUCT_FLOW_PREFIX + SystemConstant.IMPORT + examId + "_" + courseCode + "_" + paperNumber + "_" + obeCourseOutlineId;
         Object o = redisUtil.get(lockKey);
         if (Objects.nonNull(o)) {
             throw ExceptionResultEnum.ERROR.exception("正在导入试卷蓝图数据,请稍候再试!");

+ 11 - 11
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TCUsualScoreServiceImpl.java

@@ -61,13 +61,13 @@ public class TCUsualScoreServiceImpl extends ServiceImpl<TCUsualScoreMapper, TCU
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      * @throws IOException
      */
     @Override
     @Transactional
-    public Map<String, String> usualScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long teachCourseId) throws IOException {
+    public Map<String, String> usualScoreExcelImport(MultipartFile file, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) throws IOException {
         log.debug("导入Excel开始...");
         long start = System.currentTimeMillis();
         Map<String, String> messageMap = new LinkedHashMap<>();
@@ -101,7 +101,7 @@ public class TCUsualScoreServiceImpl extends ServiceImpl<TCUsualScoreMapper, TCU
                         }
                         boolean error = false;
                         List<TCUsualScoreDto> tcUsualScoreDtoList = new ArrayList<>();
-                        TCUsualScore tcUsualScore = new TCUsualScore(examId, courseCode, markPaper.getCourseName(), paperNumber, teachCourseId, sysUser.getId());
+                        TCUsualScore tcUsualScore = new TCUsualScore(examId, courseCode, markPaper.getCourseName(), paperNumber, obeCourseOutlineId, sysUser.getId());
                         for (int j = 0; j < strs.length; j++) {
                             if (Objects.isNull(strs[j]) || Objects.equals(strs[j].trim(), "")) {
                                 errorData.add("excel第").add((i + 1) + "").add("行[").add(columnNames[j] + "]为空;").add("\r\n");
@@ -137,11 +137,11 @@ public class TCUsualScoreServiceImpl extends ServiceImpl<TCUsualScoreMapper, TCU
                 }
                 if (!CollectionUtils.isEmpty(tcUsualScoreList)) {
                     successData.add("共导入").add(tcUsualScoreList.size() + "").add("条数据");
-                    List<TCUsualScore> tcUsualScoreDbSourceList = tcUsualScoreService.queryUsualScore(examId, courseCode, paperNumber, teachCourseId);
+                    List<TCUsualScore> tcUsualScoreDbSourceList = tcUsualScoreService.queryUsualScore(examId, courseCode, paperNumber, obeCourseOutlineId);
                     if (CollectionUtils.isEmpty(tcUsualScoreDbSourceList) || !CollectionUtils.isEqualCollection(tcUsualScoreDbSourceList, tcUsualScoreList)) {
                         tcUsualScoreService.removeByIds(tcUsualScoreDbSourceList.stream().map(s -> s.getId()).collect(Collectors.toList()));
                         tcUsualScoreService.saveBatch(tcUsualScoreList);
-                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, false);
+                        trBasicInfoService.clearReportData(examId, courseCode, paperNumber, obeCourseOutlineId, false);
                     }
                 }
             }
@@ -172,12 +172,12 @@ public class TCUsualScoreServiceImpl extends ServiceImpl<TCUsualScoreMapper, TCU
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public IPage<TCUsualScore> usualScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        return this.baseMapper.usualScoreList(iPage, examId, courseCode, paperNumber, teachCourseId);
+    public IPage<TCUsualScore> usualScoreList(IPage<Map> iPage, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        return this.baseMapper.usualScoreList(iPage, examId, courseCode, paperNumber, obeCourseOutlineId);
     }
 
     /**
@@ -186,17 +186,17 @@ public class TCUsualScoreServiceImpl extends ServiceImpl<TCUsualScoreMapper, TCU
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public List<TCUsualScore> queryUsualScore(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public List<TCUsualScore> queryUsualScore(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TCUsualScore> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TCUsualScore::getExamId, examId).eq(TCUsualScore::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TCUsualScore::getPaperNumber, paperNumber).or().isNull(TCUsualScore::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TCUsualScore::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TCUsualScore::getTeachCourseId, obeCourseOutlineId);
         return tcUsualScoreService.list(queryWrapper);
     }
 }

+ 30 - 30
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TRBasicInfoServiceImpl.java

@@ -92,17 +92,17 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public TRBasicInfo queryBasicInfo(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public TRBasicInfo queryBasicInfo(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TRBasicInfo> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TRBasicInfo::getExamId, examId).eq(TRBasicInfo::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TRBasicInfo::getPaperNumber, paperNumber).or().isNull(TRBasicInfo::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TRBasicInfo::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TRBasicInfo::getTeachCourseId, obeCourseOutlineId);
         return trBasicInfoService.getOne(queryWrapper);
     }
 
@@ -424,12 +424,12 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
      * @param markPaper
      * @param userId
      * @param obeCourseWeightResult
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
     @Transactional
-    public TRBasicInfo getReportView(TRBasicInfo trBasicInfo, MarkPaper markPaper, Long userId, ObeCourseWeightResult obeCourseWeightResult, Long teachCourseId) {
+    public TRBasicInfo getReportView(TRBasicInfo trBasicInfo, MarkPaper markPaper, Long userId, ObeCourseWeightResult obeCourseWeightResult, Long obeCourseOutlineId) {
         BasicSemester basicSemester = basicSemesterService.selectByExamId(markPaper.getExamId());
         Objects.requireNonNull(basicSemester, "未找到学期信息");
 
@@ -441,7 +441,7 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         }
 
         if (Objects.isNull(trBasicInfo)) {
-            trBasicInfo = new TRBasicInfo(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getCourseName(), markPaper.getPaperNumber(), teachCourseId, basicSemester.getName(), teachingObject, teacher, null, userId);
+            trBasicInfo = new TRBasicInfo(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getCourseName(), markPaper.getPaperNumber(), obeCourseOutlineId, basicSemester.getName(), teachingObject, teacher, null, userId);
         } else {
             trBasicInfo.setBasicInfo(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getCourseName(), markPaper.getPaperNumber(), basicSemester.getName(), teachingObject, teacher, null);
         }
@@ -450,7 +450,7 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         trBasicInfo.getReportResult().setCourseBasicInfo(reportCourseBasicInfoDto);
 
         //课程目标考核分布-题目信息
-        TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getPaperNumber(), teachCourseId);
+        TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getPaperNumber(), obeCourseOutlineId);
         if (Objects.isNull(tcPaperStruct) || Objects.isNull(tcPaperStruct.getPaperStructDimension())) {
             throw ExceptionResultEnum.ERROR.exception("未找到试卷蓝图信息");
         }
@@ -963,30 +963,30 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
     @Transactional
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
         QueryWrapper<TRBasicInfo> queryWrapper = new QueryWrapper<>();
         queryWrapper.lambda().eq(TRBasicInfo::getExamId, examId).eq(TRBasicInfo::getCourseCode, courseCode);
         if (Objects.nonNull(paperNumber)) {
             queryWrapper.lambda().and(w -> w.eq(TRBasicInfo::getPaperNumber, paperNumber).or().isNull(TRBasicInfo::getPaperNumber));
         }
-        queryWrapper.lambda().eq(TRBasicInfo::getTeachCourseId, teachCourseId);
+        queryWrapper.lambda().eq(TRBasicInfo::getTeachCourseId, obeCourseOutlineId);
         return trBasicInfoService.remove(queryWrapper);
     }
 
     /**
      * 查找课程评价值
      *
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public ObeCourseWeightResult findCourseWeightResultRmi(Long teachCourseId) {
-        ObeCourseWeightResult obeCourseWeightResult = obeCourseWeightService.findCourseWeight(teachCourseId);
+    public ObeCourseWeightResult findCourseWeightResultRmi(Long obeCourseOutlineId) {
+        ObeCourseWeightResult obeCourseWeightResult = obeCourseWeightService.findCourseWeight(obeCourseOutlineId);
         Objects.requireNonNull(obeCourseWeightResult, "未设置课程目标数据");
 //        Objects.requireNonNull(obeCourseWeightResult.getCustomRate(), "未设置平时成绩权重");
 //        Objects.requireNonNull(obeCourseWeightResult.getDefaultRate(), "未设置期末考试权重");
@@ -1002,12 +1002,12 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
     /**
      * 查找课程评价值
      *
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
-    public List<CourseWeightDto> findCourseWeightDtoRmi(Long teachCourseId) {
-        ObeCourseWeightResult obeCourseWeightResult = obeCourseWeightService.findCourseWeight(teachCourseId);
+    public List<CourseWeightDto> findCourseWeightDtoRmi(Long obeCourseOutlineId) {
+        ObeCourseWeightResult obeCourseWeightResult = obeCourseWeightService.findCourseWeight(obeCourseOutlineId);
         if (Objects.nonNull(obeCourseWeightResult) && !CollectionUtils.isEmpty(obeCourseWeightResult.getSubmitForm())) {
             return obeCourseWeightResult.getSubmitForm();
         }
@@ -1020,16 +1020,16 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @param clearDimension
      */
     @Override
     @Transactional
-    public void clearReportData(Long examId, String courseCode, String paperNumber, Long teachCourseId, boolean clearDimension) {
-        trExamStudentService.remove(examId, courseCode, paperNumber, teachCourseId);
-        trBasicInfoService.remove(examId, courseCode, paperNumber, teachCourseId);
+    public void clearReportData(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId, boolean clearDimension) {
+        trExamStudentService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
+        trBasicInfoService.remove(examId, courseCode, paperNumber, obeCourseOutlineId);
         if (clearDimension) {
-            TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(examId, courseCode, paperNumber, teachCourseId);
+            TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(examId, courseCode, paperNumber, obeCourseOutlineId);
             if (Objects.nonNull(tcPaperStruct)) {
                 tcPaperStruct.setPaperStructDimension(null);
                 SysUser sysUser = (SysUser) ServletUtil.getRequestUser();
@@ -1078,10 +1078,10 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
      * @param finalScoreDto
      * @param examId
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @param markPaper
      */
-    protected void fillScoreRange(FinalScoreDto finalScoreDto, Long examId, String paperNumber, Long teachCourseId, MarkPaper markPaper) {
+    protected void fillScoreRange(FinalScoreDto finalScoreDto, Long examId, String paperNumber, Long obeCourseOutlineId, MarkPaper markPaper) {
         //分数区间
         Double passScore = markPaper.getPassScore();//及格分
         Objects.requireNonNull(passScore, "及格分为空");
@@ -1095,20 +1095,20 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         //开始、结束分数区间
         Double startInterval = 0.5d, endInterval = 9.5d, increaseStartScore = passScore - startInterval,
                 increaseEndScore = increaseStartScore + startInterval + endInterval;
-        scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, teachCourseId, 1.0d, increaseStartScore));
+        scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, obeCourseOutlineId, 1.0d, increaseStartScore));
         increaseStartScore = increaseStartScore + startInterval;
         increaseEndScore = increaseStartScore + endInterval;
         if (totalScore.doubleValue() - increaseEndScore.doubleValue() == startInterval || increaseEndScore.doubleValue() >= totalScore.doubleValue()) {
             increaseEndScore = totalScore;
-            scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, teachCourseId, increaseStartScore, increaseEndScore));
+            scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, obeCourseOutlineId, increaseStartScore, increaseEndScore));
         } else {
             while (increaseEndScore.doubleValue() < totalScore.doubleValue()) {
-                scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, teachCourseId, increaseStartScore, increaseEndScore));
+                scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, obeCourseOutlineId, increaseStartScore, increaseEndScore));
                 increaseStartScore = increaseEndScore + startInterval;
                 increaseEndScore = increaseStartScore + endInterval;
                 if (totalScore.doubleValue() - increaseEndScore.doubleValue() == startInterval || increaseEndScore.doubleValue() >= totalScore.doubleValue()) {
                     increaseEndScore = totalScore;
-                    scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, teachCourseId, increaseStartScore, increaseEndScore));
+                    scoreRange.add(getScoreRangeVo(finalScoreDto.getStudentCount(), examId, markPaper.getCourseCode(), paperNumber, obeCourseOutlineId, increaseStartScore, increaseEndScore));
                 }
             }
         }
@@ -1225,13 +1225,13 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @param start
      * @param end
      * @return
      */
-    protected ScoreRangeVo getScoreRangeVo(int toltal, Long examId, String courseCode, String paperNumber, Long teachCourseId, Double start, Double end) {
-        int count = tcFinalScoreService.getCountByScoreRange(examId, courseCode, paperNumber, teachCourseId, start, end);
+    protected ScoreRangeVo getScoreRangeVo(int toltal, Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId, Double start, Double end) {
+        int count = tcFinalScoreService.getCountByScoreRange(examId, courseCode, paperNumber, obeCourseOutlineId, start, end);
         Double rate = null;
         if (toltal != 0) {
             rate = new BigDecimal(count).divide(new BigDecimal(toltal), 2, BigDecimal.ROUND_HALF_UP).setScale(2, BigDecimal.ROUND_HALF_UP).multiply(SystemConstant.PERCENT).doubleValue();

+ 3 - 3
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/TRExamStudentServiceImpl.java

@@ -192,13 +192,13 @@ public class TRExamStudentServiceImpl extends ServiceImpl<TRExamStudentMapper, T
      * @param examId
      * @param courseCode
      * @param paperNumber
-     * @param teachCourseId
+     * @param obeCourseOutlineId
      * @return
      */
     @Override
     @Transactional
-    public Boolean remove(Long examId, String courseCode, String paperNumber, Long teachCourseId) {
-        TRBasicInfo trBasicInfo = trBasicInfoService.queryBasicInfo(examId, courseCode, paperNumber, teachCourseId);
+    public Boolean remove(Long examId, String courseCode, String paperNumber, Long obeCourseOutlineId) {
+        TRBasicInfo trBasicInfo = trBasicInfoService.queryBasicInfo(examId, courseCode, paperNumber, obeCourseOutlineId);
         return Objects.nonNull(trBasicInfo) ? trExamStudentService.remove(trBasicInfo.getId()) : false;
     }
 

+ 8 - 8
distributed-print-business/src/main/resources/mapper/TCFinalScoreMapper.xml

@@ -14,8 +14,8 @@
             <if test="paperNumber != null and paperNumber != ''">
                 and t.paper_number = #{paperNumber}
             </if>
-            <if test="teachCourseId != null and teachCourseId != ''">
-                and t.teach_course_id = #{teachCourseId}
+            <if test="obeCourseOutlineId != null and obeCourseOutlineId != ''">
+                and t.teach_course_id = #{obeCourseOutlineId}
             </if>
         </where>
         order by t.student_code
@@ -38,8 +38,8 @@
             <if test="paperNumber != null and paperNumber != ''">
                 and tcfs.paper_number = #{paperNumber}
             </if>
-            <if test="teachCourseId != null and teachCourseId != ''">
-                and tcfs.teach_course_id = #{teachCourseId}
+            <if test="obeCourseOutlineId != null and obeCourseOutlineId != ''">
+                and tcfs.teach_course_id = #{obeCourseOutlineId}
             </if>
                 and tcfs.enable = true and tcus.enable = true
         </where>
@@ -57,8 +57,8 @@
             <if test="paperNumber != null and paperNumber != ''">
                 and tcfs.paper_number = #{paperNumber}
             </if>
-            <if test="teachCourseId != null and teachCourseId != ''">
-                and tcfs.teach_course_id = #{teachCourseId}
+            <if test="obeCourseOutlineId != null and obeCourseOutlineId != ''">
+                and tcfs.teach_course_id = #{obeCourseOutlineId}
             </if>
                 and tcfs.score &gt;= #{start} and tcfs.score &lt;= #{end}
                 and tcfs.enable = true
@@ -85,8 +85,8 @@
             <if test="paperNumber != null and paperNumber != ''">
                 and tcfs.paper_number = #{paperNumber}
             </if>
-            <if test="teachCourseId != null and teachCourseId != ''">
-                and tcfs.teach_course_id = #{teachCourseId}
+            <if test="obeCourseOutlineId != null and obeCourseOutlineId != ''">
+                and tcfs.teach_course_id = #{obeCourseOutlineId}
             </if>
                 and tcfs.enable = true and tcus.enable = true
         </where>

+ 3 - 3
distributed-print-business/src/main/resources/mapper/TCUsualScoreMapper.xml

@@ -8,7 +8,7 @@
                  tc.exam_id as examId,
                  tc.course_code as courseCode,
                  bc.name as courseName,
-                 tc.id AS teachCourseId,
+                 tc.id AS obeCourseOutlineId,
                  creator.real_name AS userName,
                  creator.login_name AS userLoginName
         FROM
@@ -55,8 +55,8 @@
             <if test="paperNumber != null and paperNumber != ''">
                 and t.paper_number = #{paperNumber}
             </if>
-            <if test="teachCourseId != null and teachCourseId != ''">
-                and t.teach_course_id = #{teachCourseId}
+            <if test="obeCourseOutlineId != null and obeCourseOutlineId != ''">
+                and t.teach_course_id = #{obeCourseOutlineId}
             </if>
         </where>
         order by t.student_code

Файлын зөрүү хэтэрхий том тул дарагдсан байна
+ 1 - 10
distributed-print/src/main/java/com/qmth/distributed/print/api/ObeReportController.java


+ 4 - 2
teachcloud-common/src/main/java/com/qmth/teachcloud/common/contant/SystemConstant.java

@@ -327,7 +327,7 @@ public class SystemConstant {
     public static final String COMMA_OF_CHINESE = ",";
     public static final String PAUSE_SIGN = "、";
     public static final String ORG_SPLIT = "/";
-    public static final String ORG_POINT = "\\.";
+//    public static final String ORG_POINT = "\\.";
     public static final String PUSH_OPERATE_NOTICE = "操作成功,请去基础配置 -> 系统设置 -> 同步管理中查看结果";
     public static final String EXCEL_PROTECT_KEY = "Qmth87863577";
     public static final String ZIP_ENCRYPT_PWD = "qmthzip";
@@ -341,12 +341,14 @@ public class SystemConstant {
     public static final String GET_EQUAL = "=";
     public static final String PATH_MATCH = "*";
     public static final String CATALOG_LINK = "->";
-    public static final String OPERATE_LINK = "--";
+//    public static final String OPERATE_LINK = "--";
     public static final String LIMIT1 = "limit 1";
 
     public static final Integer DEFAULT_BACKUP_COUNT = 1;
     public static final String IMPORT = ":import";
     public static final String SYNC = ":sync";
+    public static final String OBE_COURSE_REQUIREMENT_DTO_LIST = "obeCourseRequirementDtoList";
+    public static final String OBE_SUB_REQUIREMENT_DTO_MAP = "obeSubRequirementsDtoMap";
 
     /**
      * oss url过期时间

Энэ ялгаанд хэт олон файл өөрчлөгдсөн тул зарим файлыг харуулаагүй болно