浏览代码

考试统计修改

wangliang 1 年之前
父节点
当前提交
ccb01a0852
共有 1 个文件被更改,包括 4 次插入4 次删除
  1. 4 4
      themis-admin/src/main/java/com/qmth/themis/admin/api/TEExamController.java

+ 4 - 4
themis-admin/src/main/java/com/qmth/themis/admin/api/TEExamController.java

@@ -480,11 +480,11 @@ public class TEExamController {
         }
 
         List<TEExamSummary> teExamSummaryAllList = new ArrayList<>();
-        for (String s : roomCodeSet) {
-            teExamSummaryAllList.addAll(themisCacheService.addExamSummaryCache(examId, examActivityId, s));
+        if (Objects.nonNull(examActivityId)) {
+            for (String s : roomCodeSet) {
+                teExamSummaryAllList.addAll(themisCacheService.addExamSummaryCache(examId, examActivityId, s));
+            }
         }
-//        themisCacheService.addExamSummaryCache(444861201752002560L, 444861202175627264L, "01");
-//        themisCacheService.updateExamSummaryCache(444861201752002560L, 444861202175627264L, "01");
         ExamPropCountDto examPropCountDto = new ExamPropCountDto(examId, 0, 0, 0, 0, 0, new BigDecimal(0));
         if (!CollectionUtils.isEmpty(teExamSummaryAllList)) {
             Integer allCount = 0, prepareCount = 0, examCount = 0, alreadyComplete = 0, notComplete = 0;