|
@@ -1,6 +1,7 @@
|
|
|
package cn.com.qmth.stmms.biz.exam.dao;
|
|
|
|
|
|
import cn.com.qmth.stmms.biz.exam.model.ExamQuestion;
|
|
|
+
|
|
|
import org.springframework.data.domain.Sort;
|
|
|
import org.springframework.data.jpa.repository.JpaRepository;
|
|
|
import org.springframework.data.jpa.repository.JpaSpecificationExecutor;
|
|
@@ -8,6 +9,7 @@ import org.springframework.data.jpa.repository.Modifying;
|
|
|
import org.springframework.data.jpa.repository.Query;
|
|
|
|
|
|
import java.util.List;
|
|
|
+import java.util.Set;
|
|
|
|
|
|
public interface ExamQuestionDao extends JpaRepository<ExamQuestion, Integer>, JpaSpecificationExecutor<ExamQuestion> {
|
|
|
|
|
@@ -99,4 +101,7 @@ public interface ExamQuestionDao extends JpaRepository<ExamQuestion, Integer>, J
|
|
|
public long countByExamIdAndSubjectAndObjectiveAndGroupNumberIsNull(int examId, String subjectCode,
|
|
|
boolean objective);
|
|
|
|
|
|
+ @Query("select distinct q.subjectCode from ExamQuestion q where q.examId=?1 and q.objective=?2 and q.groupNumber is null ")
|
|
|
+ public Set<String> FindSubjectCodeByExamIdAndObjectiveAndGroupNumberIsNull(int examId, boolean objective);
|
|
|
+
|
|
|
}
|