From cbb51be06db9560ffaca9cd42d1f2d92b4ed3f37 Mon Sep 17 00:00:00 2001
From: guoshilong <123456>
Date: Fri, 15 Dec 2023 13:47:19 +0800
Subject: [PATCH] 添加打卡距离

---
 src/main/java/org/springblade/modules/exam/mapper/ExamPaperMapper.xml |    9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diff --git a/src/main/java/org/springblade/modules/exam/mapper/ExamPaperMapper.xml b/src/main/java/org/springblade/modules/exam/mapper/ExamPaperMapper.xml
index bd10eaa..ee0d7a5 100644
--- a/src/main/java/org/springblade/modules/exam/mapper/ExamPaperMapper.xml
+++ b/src/main/java/org/springblade/modules/exam/mapper/ExamPaperMapper.xml
@@ -592,10 +592,17 @@
             (
                 SELECT * FROM ( SELECT * FROM exam_subject_choices WHERE choices_type = 0 ORDER BY RAND( ) LIMIT 70 ) a UNION ALL
                 SELECT * FROM ( SELECT * FROM exam_subject_choices WHERE choices_type = 1 ORDER BY RAND( ) LIMIT 10 ) b UNION ALL
-                SELECT * FROM ( SELECT * FROM exam_subject_choices WHERE choices_type = 2 ORDER BY RAND( ) LIMIT 20 ) c UNION ALL
+                SELECT * FROM ( SELECT * FROM exam_subject_choices WHERE choices_type = 2 ORDER BY RAND( ) LIMIT 20 ) c
             ) esc
             LEFT JOIN exam_subject_option eso ON esc.id = eso.subject_choices_id
     </select>
+    <select id="getList" resultType="org.springblade.modules.exam.vo.ExamPaperVO">
+        SELECT * FROM ksxt_exam
+        where 1=1
+        <if test="vo.examTime != null and vo.examTime != ''">
+            AND DATE_FORMAT(start_time,'%Y-%m-%d') = DATE_FORMAT(#{vo.examTime},'%Y-%m-%d')
+        </if>
+    </select>
 
 
 </mapper>

--
Gitblit v1.9.3