瀏覽代碼

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

wangliang 3 年之前
父節點
當前提交
a588ef2748

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

@@ -467,7 +467,8 @@ public class TEExamController {
                 examPropCountDto.get().setPrepareCount(list.get(0));
                 examPropCountDto.get().setExamCount(list.get(1));
                 examPropCountDto.get().setAlreadyComplete(list.get(2));
-                examPropCountDto.get().setNotComplete(list.get(3) + list.get(4));
+//                examPropCountDto.get().setNotComplete(list.get(3) + list.get(4));
+                examPropCountDto.get().setNotComplete(list.get(3));
             }
             BigDecimal completionRate = new BigDecimal(examPropCountDto.get().getAlreadyComplete())
                     .divide(new BigDecimal(examPropCountDto.get().getAllCount()), 2, BigDecimal.ROUND_HALF_UP)

+ 14 - 12
themis-business/src/main/resources/mapper/TOeExamRecordMapper.xml

@@ -285,10 +285,10 @@
         t_oe_exam_record toer
         where
         s.id = toer.exam_student_id
-        <if test="status != null and status != '' and status == 'UN_FINISH'">
+        <!--<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>-->
                     )
         <if test="examId != null and examId != ''">
             and s.exam_id = #{examId}
@@ -328,9 +328,9 @@
                     </otherwise>
                 </choose>
             </if>
-            <if test="status != null and status != '' and status == 'UN_FINISH'">
+            <!--<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>-->
             <if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
                 and toer.warning_count &lt;= #{maxWarningCount}
             </if>
@@ -439,10 +439,10 @@
         t_oe_exam_record toer
         where
         s.id = toer.exam_student_id
-        <if test="status != null and status != '' and status == 'UN_FINISH'">
+        <!--<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>-->
                     )
         <if test="examId != null and examId != ''">
             and s.exam_id = #{examId}
@@ -482,9 +482,9 @@
                     </otherwise>
                 </choose>
             </if>
-            <if test="status != null and status != '' and status == 'UN_FINISH'">
+            <!--<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>-->
             <if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
                 and toer.warning_count &lt;= #{maxWarningCount}
             </if>
@@ -837,10 +837,10 @@
         t_oe_exam_record toer
         where
         s.id = toer.exam_student_id
-        <if test="status != null and status != '' and status == 'UN_FINISH'">
+        <!--<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>-->
                     )
         <if test="examId != null and examId != ''">
             and s.exam_id = #{examId}
@@ -882,9 +882,9 @@
                     </otherwise>
                 </choose>
             </if>
-            <if test="status != null and status != '' and status == 'UN_FINISH'">
+            <!--<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>-->
             <if test="maxWarningCount != null and maxWarningCount != '' or maxWarningCount == 0">
                 and toer.warning_count &lt;= #{maxWarningCount}
             </if>
@@ -1388,6 +1388,7 @@
         <foreach collection="roomCodeSet" item="roomCode" index="index" open="(" close=")" separator=",">
             #{roomCode}
         </foreach>
+        <!--
         union all
         select
         count(distinct toer.exam_student_id) as c
@@ -1429,6 +1430,7 @@
         ) temp
         where
         temp.id = toer.exam_student_id)
+        -->
     </select>
 
     <select id="findByOnlineInfoRecord" resultType="com.qmth.themis.business.entity.TOeExamRecord">