|
@@ -39,7 +39,7 @@ public interface PaperRepo extends JpaRepository<Paper, Long>, JpaSpecificationE
|
|
|
|
|
|
Page<Paper> findByQuestionId(Long questionId, Pageable pageable);
|
|
Page<Paper> findByQuestionId(Long questionId, Pageable pageable);
|
|
|
|
|
|
- Paper findTopByLevelAndIsSampleAndIsMissingAndSubjectAndTestAndAreaCodeOrderByUpdatedOnDesc(String level, boolean isSample, boolean isMissing, Subject subject, int test, String areaCode);
|
|
|
|
|
|
+ Paper findTopByLevelAndIsSampleAndIsMissingAndSubjectAndTestAndAreaCodeAndWorkIdOrderByUpdatedOnDesc(String level, boolean isSample, boolean isMissing, Subject subject, int test, String areaCode, Long workId);
|
|
|
|
|
|
/**
|
|
/**
|
|
* 统计各省各科试卷数量[areaCode,areaName,questionName,count]
|
|
* 统计各省各科试卷数量[areaCode,areaName,questionName,count]
|
|
@@ -104,7 +104,7 @@ public interface PaperRepo extends JpaRepository<Paper, Long>, JpaSpecificationE
|
|
"WHERE p.`question_id` = ? and p.is_missing = false " +
|
|
"WHERE p.`question_id` = ? and p.is_missing = false " +
|
|
"AND p.batch_no = (select max(batch_no) from paper where question_id = ?) " +
|
|
"AND p.batch_no = (select max(batch_no) from paper where question_id = ?) " +
|
|
" AND p.level is null " +
|
|
" AND p.level is null " +
|
|
- " GROUP BY p.`level` union "+
|
|
|
|
|
|
+ " GROUP BY p.`level` union " +
|
|
"SELECT p.`level`,COUNT(*)," +
|
|
"SELECT p.`level`,COUNT(*)," +
|
|
"SUM(IF(p.`is_rejected` = 1, 1, 0))," +
|
|
"SUM(IF(p.`is_rejected` = 1, 1, 0))," +
|
|
"SUM(IF(p.`is_arbitrated` = 1, 1, 0))" +
|
|
"SUM(IF(p.`is_arbitrated` = 1, 1, 0))" +
|