From 7524560c663902ca679db9cc7adc6cd4fae040f7 Mon Sep 17 00:00:00 2001 From: xiangpei <xiangpei@timesnew.cn> Date: 星期二, 16 七月 2024 17:11:40 +0800 Subject: [PATCH] 通知完善 --- src/main/resources/mapper/QuestionMapper.xml | 11 ++++++++++- 1 files changed, 10 insertions(+), 1 deletions(-) diff --git a/src/main/resources/mapper/QuestionMapper.xml b/src/main/resources/mapper/QuestionMapper.xml index 4129fa3..5207f9b 100644 --- a/src/main/resources/mapper/QuestionMapper.xml +++ b/src/main/resources/mapper/QuestionMapper.xml @@ -273,7 +273,7 @@ DISTINCT q.id, q.question_type, - q.correct as answer, + q.correct, ttc.content FROM t_question q @@ -373,4 +373,13 @@ INNER JOIN t_text_content ttc ON tq.info_text_content_id = ttc.id AND tq.id = #{id} AND tq.deleted = 0 </select> + <select id="countQuestionByTitle" resultType="integer"> + SELECT + COUNT(q.id) + FROM + t_question q + INNER JOIN t_text_content d on q.info_text_content_id = d.id + WHERE JSON_VALUE(d.content, '$.titleContent') = #{title} AND q.deleted = 0 + </select> + </mapper> -- Gitblit v1.8.0