wangliang 4 years ago
parent
commit
5ea0c3152e
1 changed files with 4 additions and 1 deletions
  1. 4 1
      themis-business/src/main/resources/mapper/TEExamStudentMapper.xml

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

@@ -176,8 +176,11 @@
 
 	<select id="getDoneCountByActivityIds"
 		resultType="java.util.Map">
-		select t.exam_activity_id activityId,t.room_code roomCode,count(1) cc
+		select t.exam_activity_id activityId,t.room_code roomCode,
+		count(distinct(toer.exam_student_id)) cc
 		from t_e_exam_student t
+		left join t_oe_exam_record toer on
+			toer.exam_student_id = t.id
 		where t.exam_id = #{examId} and t.current_record_id is not null
 		<if test="activityIds != null">
 			and t.exam_activity_id in