|
@@ -321,13 +321,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
select q.* from mxjb_question_collection c
|
|
select q.* from mxjb_question_collection c
|
|
|
left join learn_questions q on c.question_id = q.id
|
|
left join learn_questions q on c.question_id = q.id
|
|
|
left join dz_subject s on q.subjectId = s.subject_id
|
|
left join dz_subject s on q.subjectId = s.subject_id
|
|
|
- where c.user_id = #{userId}
|
|
|
|
|
- and q.subjectId = #{subjectId}
|
|
|
|
|
|
|
+ <if test="subjectId != null "> and q.subjectId = #{subjectId} = #{subjectId}</if>
|
|
|
</select>
|
|
</select>
|
|
|
|
|
|
|
|
<select id="selectCollectInfo" parameterType="java.util.HashMap" resultMap="LearnQuestionsResult">
|
|
<select id="selectCollectInfo" parameterType="java.util.HashMap" resultMap="LearnQuestionsResult">
|
|
|
SELECT q.id from mxjb_question_collection c
|
|
SELECT q.id from mxjb_question_collection c
|
|
|
- left join questions q on c.question_id = q.id
|
|
|
|
|
|
|
+ left join learn_questions q on c.question_id = q.id
|
|
|
where user_id = #{userId}
|
|
where user_id = #{userId}
|
|
|
and c.question_id in
|
|
and c.question_id in
|
|
|
<foreach item="id" collection="ids" open="(" separator="," close=")">
|
|
<foreach item="id" collection="ids" open="(" separator="," close=")">
|