Răsfoiți Sursa

在线考试2022/05/20临时上线需求更改,缺考修改

wangliang 3 ani în urmă
părinte
comite
d0ab7cbf0b

+ 1 - 1
themis-business/src/main/java/com/qmth/themis/business/bean/admin/InvigilateListHistoryBean.java

@@ -34,6 +34,7 @@ public class InvigilateListHistoryBean implements Serializable {
 
     @JsonSerialize(using = ToStringSerializer.class)
     @ApiModelProperty(name = "考试id")
+    @ExcelProperty(name = "考试ID", width = 30, index = 4)
     private Long examId;
 
     @JsonSerialize(using = ToStringSerializer.class)
@@ -46,7 +47,6 @@ public class InvigilateListHistoryBean implements Serializable {
 
     @JsonSerialize(using = ToStringSerializer.class)
     @ApiModelProperty(name = "考试记录id")
-    @ExcelProperty(name = "考试ID", width = 30, index = 4)
     private Long examRecordId;
 
     @ApiModelProperty(name = "证件号")

+ 1 - 1
themis-business/src/main/java/com/qmth/themis/business/bean/admin/InvigilateListVideoBean.java

@@ -338,7 +338,7 @@ public class InvigilateListVideoBean implements Serializable {
         if (statusCode != null && Objects.equals(ExamRecordStatusEnum.FIRST_PREPARE, statusCode)) {
             return "已待考";
         } else if (statusCode != null && Objects.equals(ExamRecordStatusEnum.BREAK_OFF, statusCode)) {
-            return "通讯故障";
+            return "已中断";
         } else if (statusCode != null && (Objects.equals(ExamRecordStatusEnum.ANSWERING, statusCode) || Objects.equals(ExamRecordStatusEnum.RESUME_PREPARE, statusCode) || Objects.equals(ExamRecordStatusEnum.BREAK_OFF, statusCode))) {
             return "考试中";
         } else {

+ 4 - 4
themis-business/src/main/resources/mapper/TEExamStudentMapper.xml

@@ -286,7 +286,7 @@
         t_e_exam_student t
         left join t_e_exam_activity f on
         t.exam_activity_id = f.id
-        join t_e_exam tee on
+        left join t_e_exam tee on
         tee.id = t.exam_id
         where
         NOT EXISTS(
@@ -331,13 +331,13 @@
         t.id
         from
         t_oe_exam_record toer
-        join t_e_exam_student t on
+        left join t_e_exam_student t on
         t.id = toer.exam_student_id
         and t.exam_id = toer.exam_id
         and t.exam_activity_id = toer.exam_activity_id
-        join t_e_exam_activity f on
+        left join t_e_exam_activity f on
         t.exam_activity_id = f.id
-        join t_e_exam tee on
+        left join t_e_exam tee on
         tee.id = t.exam_id
         where
         toer.exam_id = #{examId}

+ 31 - 7
themis-business/src/main/resources/mapper/TOeExamRecordMapper.xml

@@ -284,7 +284,12 @@
         from
         t_oe_exam_record toer
         where
-        s.id = toer.exam_student_id)
+        s.id = toer.exam_student_id
+        <if test="status != null and status != '' and status == 'UN_FINISH'">
+            and (toer.STATUS = 'FINISHED' or toer.STATUS = 'PERSISTED')
+            and toer.first_start_time is not null
+        </if>
+                    )
         <if test="examId != null and examId != ''">
             and s.exam_id = #{examId}
         </if>
@@ -323,6 +328,9 @@
                     </otherwise>
                 </choose>
             </if>
+            <if test="status != null and status != '' and status == 'UN_FINISH'">
+                and (toer.first_start_time is null or toer.first_prepare_time is null)
+            </if>
             <if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
                 and toer.warning_count &lt;= #{maxWarningCount}
             </if>
@@ -430,7 +438,12 @@
         from
         t_oe_exam_record toer
         where
-        s.id = toer.exam_student_id)
+        s.id = toer.exam_student_id
+        <if test="status != null and status != '' and status == 'UN_FINISH'">
+            and (toer.STATUS = 'FINISHED' or toer.STATUS = 'PERSISTED')
+            and toer.first_start_time is not null
+        </if>
+                    )
         <if test="examId != null and examId != ''">
             and s.exam_id = #{examId}
         </if>
@@ -469,6 +482,9 @@
                     </otherwise>
                 </choose>
             </if>
+            <if test="status != null and status != '' and status == 'UN_FINISH'">
+                and (toer.first_start_time is null or toer.first_prepare_time is null)
+            </if>
             <if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
                 and toer.warning_count &lt;= #{maxWarningCount}
             </if>
@@ -820,7 +836,12 @@
         from
         t_oe_exam_record toer
         where
-        s.id = toer.exam_student_id)
+        s.id = toer.exam_student_id
+        <if test="status != null and status != '' and status == 'UN_FINISH'">
+            and (toer.STATUS = 'FINISHED' or toer.STATUS = 'PERSISTED')
+            and toer.first_start_time is not null
+        </if>
+                    )
         <if test="examId != null and examId != ''">
             and s.exam_id = #{examId}
         </if>
@@ -861,6 +882,9 @@
                     </otherwise>
                 </choose>
             </if>
+            <if test="status != null and status != '' and status == 'UN_FINISH'">
+                and (toer.first_start_time is null or toer.first_prepare_time is null)
+            </if>
             <if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
                 and toer.warning_count &lt;= #{maxWarningCount}
             </if>
@@ -1349,7 +1373,7 @@
         t_e_exam_student t
         left join t_e_exam_activity f on
         t.exam_activity_id = f.id
-        join t_e_exam tee on
+        left join t_e_exam tee on
         tee.id = t.exam_id
         where
         NOT EXISTS(
@@ -1369,13 +1393,13 @@
         count(distinct toer.exam_student_id) as c
         from
         t_oe_exam_record toer
-        join t_e_exam_student t on
+        left join t_e_exam_student t on
         t.id = toer.exam_student_id
         and t.exam_id = toer.exam_id
         and t.exam_activity_id = toer.exam_activity_id
-        join t_e_exam_activity f on
+        left join t_e_exam_activity f on
         t.exam_activity_id = f.id
-        join t_e_exam tee on
+        left join t_e_exam tee on
         tee.id = t.exam_id
         where
         toer.exam_id = #{examId} and t.room_code in