|
@@ -20,7 +20,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<include refid="selectQuestionWrongVo"/>
|
|
|
<where>
|
|
|
<if test="userId != null and userId !='' "> and user_id = #{userId}</if>
|
|
|
- <if test="questionId != null and questionId != '' "> and question_id = #{questionId}</if>
|
|
|
<if test="km != null and km!='' "> and km = #{km}</if>
|
|
|
</where>
|
|
|
</select>
|
|
@@ -32,7 +31,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
select q1.* from question_info q1 join question_wrong q2 on q1.id = q2.question_id
|
|
|
<where>
|
|
|
<if test="userId != null and userId !='' "> and q2.user_id = #{userId}</if>
|
|
|
- <if test="questionId != null and questionId != '' "> and q2.question_id = #{questionId}</if>
|
|
|
<if test="km != null and km!='' "> and q2.km = #{km}</if>
|
|
|
</where>
|
|
|
order by q2.create_time
|
|
@@ -43,7 +41,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
select q1.id,q2.create_time from question_info q1 join question_wrong q2 on q1.id = q2.question_id
|
|
|
<where>
|
|
|
<if test="userId != null and userId !='' "> and q2.user_id = #{userId}</if>
|
|
|
- <if test="questionId != null and questionId != '' "> and q2.question_id = #{questionId}</if>
|
|
|
<if test="km != null and km!='' "> and q2.km = #{km}</if>
|
|
|
</where>
|
|
|
order by q2.create_time
|
|
@@ -54,7 +51,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
select count(1) from question_info q1 join question_wrong q2 on q1.id = q2.question_id
|
|
|
<where>
|
|
|
<if test="userId != null and userId !='' "> and q2.user_id = #{userId}</if>
|
|
|
- <if test="questionId != null and questionId != '' "> and q2.question_id = #{questionId}</if>
|
|
|
<if test="km != null and km!='' "> and q2.km = #{km}</if>
|
|
|
</where>
|
|
|
|