|
@@ -10,6 +10,7 @@ import org.springframework.data.jpa.repository.Query;
|
|
import org.springframework.data.repository.PagingAndSortingRepository;
|
|
import org.springframework.data.repository.PagingAndSortingRepository;
|
|
|
|
|
|
import cn.com.qmth.stmms.biz.exam.model.ExamStudent;
|
|
import cn.com.qmth.stmms.biz.exam.model.ExamStudent;
|
|
|
|
+import cn.com.qmth.stmms.common.enums.ScanCheck;
|
|
|
|
|
|
public interface ExamStudentDao
|
|
public interface ExamStudentDao
|
|
extends PagingAndSortingRepository<ExamStudent, Integer>, JpaSpecificationExecutor<ExamStudent> {
|
|
extends PagingAndSortingRepository<ExamStudent, Integer>, JpaSpecificationExecutor<ExamStudent> {
|
|
@@ -59,8 +60,8 @@ public interface ExamStudentDao
|
|
public void updateManualAbsent(int id, boolean manualAbsent);
|
|
public void updateManualAbsent(int id, boolean manualAbsent);
|
|
|
|
|
|
@Modifying
|
|
@Modifying
|
|
- @Query("update ExamStudent s set s.manualAbsent=?3 where s.examId=?1 and s.examNumber=?2")
|
|
|
|
- public void updateManualAbsent(int examId, String examNumber, boolean manualAbsent);
|
|
|
|
|
|
+ @Query("update ExamStudent s set s.manualAbsent=?3 and s.scanCheck=?4 where s.examId=?1 and s.examNumber=?2")
|
|
|
|
+ public void updateManualAbsent(int examId, String examNumber, boolean manualAbsent, ScanCheck s);
|
|
|
|
|
|
@Modifying
|
|
@Modifying
|
|
@Query("update ExamStudent s set s.manualAbsent=0 where s.examId=?1")
|
|
@Query("update ExamStudent s set s.manualAbsent=0 where s.examId=?1")
|
|
@@ -125,4 +126,7 @@ public interface ExamStudentDao
|
|
@Query(value = "select s.id from eb_exam_student s where 1=1 and s.id in (select m.student_id from m_library m where 1=1 and m.marker_id in (select m.id from eb_marker m where 1=1 and m.name = ?1))", nativeQuery = true)
|
|
@Query(value = "select s.id from eb_exam_student s where 1=1 and s.id in (select m.student_id from m_library m where 1=1 and m.marker_id in (select m.id from eb_marker m where 1=1 and m.name = ?1))", nativeQuery = true)
|
|
public List<String[]> findIdsByMarkName(String markName);
|
|
public List<String[]> findIdsByMarkName(String markName);
|
|
|
|
|
|
|
|
+ @Query("select s from ExamStudent s where s.examId=?1 and s.manualAbsent = ?2 ")
|
|
|
|
+ public List<ExamStudent> findByExamIdAndManualAbsent(int examId, boolean manualAbsent);
|
|
|
|
+
|
|
}
|
|
}
|