瀏覽代碼

课程目标达成度修改

wangliang 1 年之前
父節點
當前提交
84b14f8428

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

@@ -8,7 +8,6 @@ import com.qmth.teachcloud.common.base.BaseEntity;
 import io.swagger.annotations.ApiModel;
 import io.swagger.annotations.ApiModelProperty;
 
-import javax.validation.constraints.NotNull;
 import java.io.Serializable;
 
 /**
@@ -129,6 +128,8 @@ public class TRBasicInfo extends BaseEntity implements Serializable {
 
     protected void setValue(TRBasicInfo trBasicInfo) {
         this.examId = trBasicInfo.getExamId();
+        this.cultureProgramId = trBasicInfo.getCultureProgramId();
+        this.courseId = trBasicInfo.getCourseId();
         this.courseCode = trBasicInfo.getCourseCode();
         this.courseName = trBasicInfo.getCourseName();
         this.paperNumber = trBasicInfo.getPaperNumber();
@@ -149,7 +150,7 @@ public class TRBasicInfo extends BaseEntity implements Serializable {
         this.courseEvaluationResultDetail = trBasicInfo.getCourseEvaluationResultDetail();
     }
 
-    public void setBasicInfo(Long examId, String courseCode, String courseName, String paperNumber, String openTime, String teachingObject, String teacher, Integer participantCount) {
+    public void setBasicInfo(Long examId, String courseCode, String courseName, String paperNumber, String openTime, String teachingObject, String teacher, Integer participantCount, Long cultureProgramId, Long courseId) {
         this.examId = examId;
         this.courseCode = courseCode;
         this.courseName = courseName;
@@ -160,6 +161,8 @@ public class TRBasicInfo extends BaseEntity implements Serializable {
         this.participantCount = participantCount;
         this.enable = true;
         this.reportResult = new ReportResult();
+        this.cultureProgramId = cultureProgramId;
+        this.courseId = courseId;
     }
 
     public Long getCultureProgramId() {

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

@@ -75,6 +75,7 @@ public interface PrintCommonService {
     BasicAttachment saveAttachmentPdfFromHtml(String fileName, String htmlContent, Long userId, List<PdfDto> localFileList, List<File> fileTempList) throws IOException;
 
     BasicAttachment saveAttachmentPdfFromHtml(String fileName, File file, Long userId, List<PdfDto> localFileList, List<File> fileTempList, PageSizeEnum pageSizeEnum) throws IOException;
+
     /**
      * 保存html附件和该html转成pdf的附件
      *
@@ -280,12 +281,13 @@ public interface PrintCommonService {
      * 成绩管理导入excel校验
      *
      * @param file
-     * @param examId
+     * @param cultureProgramId
      * @param courseCode
      * @param paperNumber
+     * @param courseId
      * @return
      */
-    public MarkPaper scoreImportExcelVaild(MultipartFile file, Long cultureProgramId, String courseCode, String paperNumber) throws IOException;
+    public MarkPaper scoreImportExcelVaild(MultipartFile file, Long cultureProgramId, String courseCode, String paperNumber, Long courseId) throws IOException;
 
     /**
      * 获取阅卷数据
@@ -293,9 +295,10 @@ public interface PrintCommonService {
      * @param examId
      * @param courseCode
      * @param paperNumber
+     * @param courseId
      * @return
      */
-    public MarkPaper getMarkPaper(Long examId, String courseCode, String paperNumber);
+    public MarkPaper getMarkPaper(Long examId, String courseCode, String paperNumber, Long courseId);
 
     /**
      * 成绩管理动态生成excel
@@ -313,11 +316,11 @@ public interface PrintCommonService {
      *
      * @param iPage
      * @param cultureProgramId 培养方案id
-     * @param semesterId 学期id
-     * @param courseId 课程id
+     * @param semesterId       学期id
+     * @param courseId         课程id
      * @return
      */
-    public IPage<ObeScoreResult> scoreList(IPage<Map> iPage, Long cultureProgramId,Long semesterId, Long courseId);
+    public IPage<ObeScoreResult> scoreList(IPage<Map> iPage, Long cultureProgramId, Long semesterId, Long courseId);
 
     /**
      * 获取成绩管理需要的锁

+ 29 - 8
distributed-print-business/src/main/java/com/qmth/distributed/print/business/service/impl/PrintCommonServiceImpl.java

@@ -15,7 +15,6 @@ import com.qmth.distributed.print.business.bean.dto.PdfSignDto;
 import com.qmth.distributed.print.business.bean.excel.ExcelField;
 import com.qmth.distributed.print.business.bean.params.ExamTaskStudentObjectParam;
 import com.qmth.distributed.print.business.bean.result.ObeScoreResult;
-import com.qmth.distributed.print.business.bean.result.ScoreResult;
 import com.qmth.distributed.print.business.entity.*;
 import com.qmth.distributed.print.business.enums.ExamDetailStatusEnum;
 import com.qmth.distributed.print.business.enums.PrintPlanStatusEnum;
@@ -387,21 +386,43 @@ public class PrintCommonServiceImpl implements PrintCommonService {
     }
 
 
+    /**
+     * @param file
+     * @param cultureProgramId
+     * @param courseCode
+     * @param paperNumber
+     * @param courseId
+     * @param courseCode
+     * @param paperNumber
+     * @param courseId
+     * @return
+     */
     @Override
-    public MarkPaper scoreImportExcelVaild(MultipartFile file, Long cultureProgramId, String courseCode, String paperNumber) throws IOException {
+    public MarkPaper scoreImportExcelVaild(MultipartFile file, Long cultureProgramId, String courseCode, String paperNumber, Long courseId) throws IOException {
         String reqFileMd5 = ServletUtil.getRequestMd5();
         String fileMd5 = DigestUtils.md5Hex(file.getBytes());
         if (!Objects.equals(fileMd5, reqFileMd5)) {
             throw ExceptionResultEnum.MD5_EQUALS_FALSE.exception();
         }
-        return this.getMarkPaper(null, courseCode, paperNumber);
+        return this.getMarkPaper(null, courseCode, paperNumber, courseId);
     }
 
+    /**
+     * 获取阅卷数据
+     *
+     * @param examId
+     * @param courseCode
+     * @param paperNumber
+     * @param courseId
+     * @return
+     */
     @Override
-    public MarkPaper getMarkPaper(Long examId, String courseCode, String paperNumber) {
-            BasicCourse basicCourse = basicCourseService.getByCode(courseCode);
-            Objects.requireNonNull(basicCourse, "未找到基础课程信息");
-        return new MarkPaper(examId, courseCode, basicCourse.getName(), paperNumber, 100d, 60d);
+    public MarkPaper getMarkPaper(Long examId, String courseCode, String paperNumber, Long courseId) {
+        BasicCourse basicCourse = null;
+        if (Objects.nonNull(courseId)) {
+            basicCourse = basicCourseService.getById(courseId);
+        }
+        return new MarkPaper(examId, Objects.nonNull(basicCourse) ? basicCourse.getCode() : null, Objects.nonNull(basicCourse) ? basicCourse.getName() : null, paperNumber, 100d, 60d);
     }
 
     /**
@@ -505,7 +526,7 @@ public class PrintCommonServiceImpl implements PrintCommonService {
 
 
     @Override
-    public IPage<ObeScoreResult> scoreList(IPage<Map> iPage, Long cultureProgramId,Long semesterId, Long courseId) {
+    public IPage<ObeScoreResult> scoreList(IPage<Map> iPage, Long cultureProgramId, Long semesterId, Long courseId) {
         SysUser sysUser = (SysUser) ServletUtil.getRequestUser();
         DataPermissionRule dpr = basicRoleDataPermissionService.findDataPermission(sysUser.getSchoolId(), sysUser.getId(), ServletUtil.getRequest().getServletPath());
         return tcUsualScoreMapper.scoreList(iPage, cultureProgramId, semesterId, courseId, dpr);

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

@@ -79,7 +79,6 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
     @Resource
     BasicCourseService basicCourseService;
 
-
     @Override
     @Transactional
     public Map<String, String> finalScoreExcelImport(MultipartFile file, Long examId, Long courseId, String paperNumber, Long cultureProgramId) {
@@ -87,7 +86,7 @@ public class TCFinalScoreServiceImpl extends ServiceImpl<TCFinalScoreMapper, TCF
         long start = System.currentTimeMillis();
         Map<String, String> messageMap = new LinkedHashMap<>();
         try {
-            MarkPaper markPaper = printCommonService.scoreImportExcelVaild(file, examId, basicCourseService.getById(courseId).getCode(), paperNumber);
+            MarkPaper markPaper = printCommonService.scoreImportExcelVaild(file, examId, null, paperNumber, courseId);
             Double totalScore = 100d;
 
             StringJoiner errorData = new StringJoiner("");

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

@@ -74,6 +74,14 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
     @Resource
     ObeCourseOutlineService obeCourseOutlineService;
 
+    /**
+     * 根据考试id/课程编码/试卷编码查询数据库数据
+     *
+     * @param cultureProgramId
+     * @param courseId
+     * @param paperNumber
+     * @return
+     */
     @Override
     @Transactional
     public Boolean remove(Long cultureProgramId, Long courseId, String paperNumber) {
@@ -85,7 +93,6 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
         return tcPaperStructService.remove(queryWrapper);
     }
 
-
     @Override
     @Transactional
     public Map<String, String> paperStructExcelImport(MultipartFile file, Long cultureProgramId, Long courseId, String paperNumber) {
@@ -93,7 +100,7 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
         long start = System.currentTimeMillis();
         Map<String, String> messageMap = new LinkedHashMap<>();
         try {
-            MarkPaper markPaper = printCommonService.scoreImportExcelVaild(file, cultureProgramId, basicCourseService.getById(courseId).getCode(), paperNumber);
+            MarkPaper markPaper = printCommonService.scoreImportExcelVaild(file, cultureProgramId, null, paperNumber, courseId);
             StringJoiner errorData = new StringJoiner("");
             StringJoiner successData = new StringJoiner("");
 
@@ -178,7 +185,15 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
         return messageMap;
     }
 
-
+    /**
+     * 试卷同步
+     *
+     * @param examId
+     * @param courseId
+     * @param paperNumber
+     * @param cultureProgramId
+     * @return
+     */
     @Override
     @Transactional
     public Map<String, String> paperStructSync(Long examId, Long courseId, String paperNumber, Long cultureProgramId) {
@@ -231,7 +246,7 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
                 tcPaperStruct.updateInfo(sysUser.getId());
             } else {
                 tcPaperStructService.remove(cultureProgramId, courseId, paperNumber);
-                MarkPaper markPaper = printCommonService.getMarkPaper(examId, basicCourseService.getById(courseId).getCode(), paperNumber);
+                MarkPaper markPaper = printCommonService.getMarkPaper(examId, null, paperNumber, courseId);
                 ObeCourseWeightResult obeCourseWeightResult = trBasicInfoService.findCourseWeightResultRmi(obeCourseOutline.getId());
                 tcPaperStruct = new TCPaperStruct(cultureProgramId, courseId, markPaper.getCourseCode(), markPaper.getCourseName(), paperNumber, JacksonUtil.parseJson(paperStructDimensionResultList), sysUser.getId(), obeCourseWeightResult.getDimensionSign());
                 List<MarkQuestion> markQuestionList = markQuestionService.listQuestionByExamIdAndPaperNumberAndPaperType(examId, paperNumber, null);
@@ -283,7 +298,13 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
         return tcPaperStructService.getOne(queryWrapper);
     }
 
-
+    /**
+     * 获取同步锁
+     *
+     * @param cultureProgramId
+     * @param courseId
+     * @param paperNumber
+     */
     @Override
     public void getPaperStructSyncLock(Long cultureProgramId, Long courseId, String paperNumber) {
         String lockKey = SystemConstant.REDIS_PAPER_STRUCT_FLOW_PREFIX + SystemConstant.SYNC + cultureProgramId + "_" + courseId + "_" + paperNumber;
@@ -293,7 +314,13 @@ public class TCPaperStructServiceImpl extends ServiceImpl<TCPaperStructMapper, T
         }
     }
 
-
+    /**
+     * 获取导入锁
+     *
+     * @param cultureProgramId
+     * @param courseId
+     * @param paperNumber
+     */
     @Override
     public void getPaperStructImportLock(Long cultureProgramId, Long courseId, String paperNumber) {
         String lockKey = SystemConstant.REDIS_PAPER_STRUCT_FLOW_PREFIX + SystemConstant.IMPORT + cultureProgramId + "_" + courseId + "_" + paperNumber;

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

@@ -116,7 +116,7 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         ReportScoreViewDto reportScoreViewDto = null;
         TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(trBasicInfo.getCultureProgramId(), trBasicInfo.getCourseId(), trBasicInfo.getPaperNumber());
         if (Objects.nonNull(tcPaperStruct) && Objects.nonNull(tcPaperStruct.getPaperStruct()) && Objects.nonNull(tcPaperStruct.getTotalScore())) {
-            BasicCourse basicCourse = basicCourseService.getByCode(trBasicInfo.getCourseCode());
+            BasicCourse basicCourse = basicCourseService.getById(trBasicInfo.getCourseId());
             markPaper = new MarkPaper(markPaper.getExamId(), markPaper.getCourseCode(), basicCourse.getName(), markPaper.getPaperNumber(), tcPaperStruct.getTotalScore(), tcPaperStruct.getPassScore());
         }
         fillScoreRange(finalScoreDto, trBasicInfo.getExamId(), trBasicInfo.getPaperNumber(), trBasicInfo.getCultureProgramId(), trBasicInfo.getCourseId(), markPaper);
@@ -441,14 +441,14 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         if (Objects.isNull(trBasicInfo)) {
             trBasicInfo = new TRBasicInfo(cultureProgramId, basicCourseService.findByCourseCode(markPaper.getCourseCode(), basicSemester.getSchoolId()).getId(), markPaper.getCourseCode(), markPaper.getCourseName(), markPaper.getPaperNumber(), basicSemester.getName(), teachingObject, teacher, null, userId);
         } else {
-            trBasicInfo.setBasicInfo(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getCourseName(), markPaper.getPaperNumber(), basicSemester.getName(), teachingObject, teacher, null);
+            trBasicInfo.setBasicInfo(markPaper.getExamId(), markPaper.getCourseCode(), markPaper.getCourseName(), markPaper.getPaperNumber(), basicSemester.getName(), teachingObject, teacher, null, cultureProgramId, courseId);
         }
         //课程基本情况
         ReportCourseBasicInfoDto reportCourseBasicInfoDto = new ReportCourseBasicInfoDto(trBasicInfo);
         trBasicInfo.getReportResult().setCourseBasicInfo(reportCourseBasicInfoDto);
 
         //课程目标考核分布-题目信息
-        TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(cultureProgramId, basicCourseService.findByCourseCode(markPaper.getCourseCode(), basicSemester.getSchoolId()).getId(), markPaper.getPaperNumber());
+        TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(cultureProgramId, courseId, markPaper.getPaperNumber());
         if (Objects.isNull(tcPaperStruct) || Objects.isNull(tcPaperStruct.getPaperStructDimension())) {
             throw ExceptionResultEnum.ERROR.exception("未找到试卷蓝图信息");
         }
@@ -640,7 +640,7 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         // 表格合并,根据坐标
         MergeCellRule mergeCellRule2 = MergeCellRule.builder().map(MergeCellRule.Grid.of(0, 0), MergeCellRule.Grid.of(1, 0)).
                 map(MergeCellRule.Grid.of(0, 1), MergeCellRule.Grid.of(0, list.size())).
-                map(MergeCellRule.Grid.of(rowRenderData2.length - 1, 0), MergeCellRule.Grid.of(rowRenderData2.length - 1, 1)).
+                map(MergeCellRule.Grid.of(0, rowRenderData2.length - 1), MergeCellRule.Grid.of(1, rowRenderData2.length - 1)).
                 build();
 
         Tables.TableBuilder tableBuilder2 = Tables.ofPercentWidth(tbPercentWidth);
@@ -984,6 +984,30 @@ public class TRBasicInfoServiceImpl extends ServiceImpl<TRBasicInfoMapper, TRBas
         if (CollectionUtils.isEmpty(courseWeightDtoList)) {
             throw ExceptionResultEnum.ERROR.exception("未设置课程目标评价方式");
         }
+        ObeCourseOutline obeCourseOutline = obeCourseOutlineService.getById(obeCourseOutlineId);
+        TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(obeCourseOutline.getCultureProgramId(), obeCourseOutline.getCourseId(), null);
+        if (Objects.nonNull(tcPaperStruct) && Objects.nonNull(tcPaperStruct.getPaperStructDimension())) {
+            List<PaperStructDimensionResult> paperStructDimensionResultList = GsonUtil.fromJson(tcPaperStruct.getPaperStructDimension(), new TypeToken<List<PaperStructDimensionResult>>() {
+
+            }.getType());
+            for (CourseWeightDto c : obeCourseWeightResult.getSubmitForm()) {
+                Double score = paperStructDimensionResultList.stream().filter(s -> Objects.equals(s.getCourseTargetName(), c.getCourseTargetName()))
+                        .mapToDouble(PaperStructDimensionResult::getScore).sum();
+                Objects.requireNonNull(c.getTotalWeight(), "[" + c.getCourseTargetName() + "]未设置权重");
+                ////                Objects.requireNonNull(c.getTotalScore(), "[" + c.getCourseTargetName() + "]未设置目标分值");
+                //                if (new BigDecimal(score).compareTo(c.getTotalWeight()) == 1) {
+                //                    trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, false);
+                //                    throw ExceptionResultEnum.ERROR.exception("[" + c.getCourseTargetName() + "]包含的小题总分与权重设置不一致,请到期末成绩--试卷蓝图设置里调整");
+                //                }
+                List<CourseWeightDetailDto> courseWeightDetailDtoList = c.getEvaluationList();
+                for (CourseWeightDetailDto courseWeightDetailDto : courseWeightDetailDtoList) {
+                    if (Objects.equals(courseWeightDetailDto.getEvaluationName(), SystemConstant.FINAL_SCORE_STR)) {
+                        courseWeightDetailDto.setTargetScore(new BigDecimal(score));
+                        break;
+                    }
+                }
+            }
+        }
         return obeCourseWeightResult;
     }
 

+ 1 - 1
distributed-print/src/main/java/com/qmth/distributed/print/api/TCPaperStructController.java

@@ -179,7 +179,7 @@ public class TCPaperStructController {
         SysUser sysUser = (SysUser) ServletUtil.getRequestUser();
         TCPaperStruct tcPaperStructDb = tcPaperStructService.queryPaperStruct(paperStructParams.getCultureProgramId(), paperStructParams.getCourseId(), paperStructParams.getPaperNumber());
         if (Objects.isNull(tcPaperStructDb)) {
-            MarkPaper markPaper = printCommonService.getMarkPaper(paperStructParams.getExamId(), paperStructParams.getCourseCode(), paperStructParams.getPaperNumber());
+            MarkPaper markPaper = printCommonService.getMarkPaper(paperStructParams.getExamId(), paperStructParams.getCourseCode(), paperStructParams.getPaperNumber(), paperStructParams.getCourseId());
             tcPaperStructDb = new TCPaperStruct(paperStructParams.getCultureProgramId(), paperStructParams.getCourseId(), paperStructParams.getCourseCode(), markPaper.getCourseName(), paperStructParams.getPaperNumber(), JacksonUtil.parseJson(paperStructParams.getPaperStruct()), sysUser.getId(), obeCourseWeightResult.getDimensionSign());
             tcPaperStructService.save(tcPaperStructDb);
         } else {

+ 2 - 24
distributed-print/src/main/java/com/qmth/distributed/print/api/TRBasicInfoController.java

@@ -130,30 +130,8 @@ public class TRBasicInfoController {
         ObeCourseWeightResult obeCourseWeightResult = trBasicInfoService.findCourseWeightResultRmi(obeCourseOutline.getId());
         log.info("ObeCourseWeightResult:{}", JacksonUtil.parseJson(obeCourseWeightResult));
         TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(cultureProgramId, courseId, paperNumber);
-        if (Objects.nonNull(tcPaperStruct) && Objects.nonNull(tcPaperStruct.getPaperStructDimension())) {
-            List<PaperStructDimensionResult> paperStructDimensionResultList = GsonUtil.fromJson(tcPaperStruct.getPaperStructDimension(), new TypeToken<List<PaperStructDimensionResult>>() {
-
-            }.getType());
-            for (CourseWeightDto c : obeCourseWeightResult.getSubmitForm()) {
-                Double score = paperStructDimensionResultList.stream().filter(s -> Objects.equals(s.getCourseTargetName(), c.getCourseTargetName()))
-                        .mapToDouble(PaperStructDimensionResult::getScore).sum();
-                Objects.requireNonNull(c.getTotalWeight(), "[" + c.getCourseTargetName() + "]未设置权重");
-                ////                Objects.requireNonNull(c.getTotalScore(), "[" + c.getCourseTargetName() + "]未设置目标分值");
-                //                if (new BigDecimal(score).compareTo(c.getTotalWeight()) == 1) {
-                //                    trBasicInfoService.clearReportData(examId, courseCode, paperNumber, teachCourseId, false);
-                //                    throw ExceptionResultEnum.ERROR.exception("[" + c.getCourseTargetName() + "]包含的小题总分与权重设置不一致,请到期末成绩--试卷蓝图设置里调整");
-                //                }
-                List<CourseWeightDetailDto> courseWeightDetailDtoList = c.getEvaluationList();
-                for (CourseWeightDetailDto courseWeightDetailDto : courseWeightDetailDtoList) {
-                    if (Objects.equals(courseWeightDetailDto.getEvaluationName(), SystemConstant.FINAL_SCORE_STR)) {
-                        courseWeightDetailDto.setTargetScore(new BigDecimal(score));
-                        break;
-                    }
-                }
-            }
-        }
 
-        MarkPaper markPaper = printCommonService.getMarkPaper(null, basicCourse.getCode(), tcPaperStruct.getPaperNumber());
+        MarkPaper markPaper = printCommonService.getMarkPaper(null, basicCourse.getCode(), tcPaperStruct.getPaperNumber(), courseId);
         if (Objects.isNull(trBasicInfo)) {
             trBasicInfo = trBasicInfoService.getReportView(trBasicInfo, markPaper, sysUser.getId(),
                     obeCourseWeightResult, cultureProgramId, courseId);
@@ -211,7 +189,7 @@ public class TRBasicInfoController {
             if (Objects.isNull(trBasicInfoDb)) {
                 trBasicInfoDb = new TRBasicInfo(trBasicInfo, sysUser.getId());
                 TCPaperStruct tcPaperStruct = tcPaperStructService.queryPaperStruct(trBasicInfo.getCultureProgramId(), trBasicInfo.getCourseId(), trBasicInfo.getPaperNumber());
-                MarkPaper markPaper = printCommonService.getMarkPaper(trBasicInfo.getExamId(), trBasicInfo.getCourseCode(), Objects.nonNull(tcPaperStruct) ? tcPaperStruct.getPaperNumber() : trBasicInfo.getPaperNumber());
+                MarkPaper markPaper = printCommonService.getMarkPaper(trBasicInfo.getExamId(), trBasicInfo.getCourseCode(), Objects.nonNull(tcPaperStruct) ? tcPaperStruct.getPaperNumber() : trBasicInfo.getPaperNumber(), trBasicInfo.getCourseId());
                 ObeCourseOutline obeCourseOutline = obeCourseOutlineService.findByCultureProgramIdAndCourseId(trBasicInfo.getCultureProgramId(), trBasicInfo.getCourseId());
                 trBasicInfoDb = trBasicInfoService.getReportView(trBasicInfoDb, markPaper, sysUser.getId(), trBasicInfoService.findCourseWeightResultRmi(obeCourseOutline.getId()), trBasicInfo.getCultureProgramId(), trBasicInfo.getCourseId());
             } else {