|
@@ -32,6 +32,12 @@
|
|
|
<if test="sexType != 3">
|
|
|
and c.sex_type in ('3',#{sexType})
|
|
|
</if>
|
|
|
+ <if test="inputIds != null and inputIds.size > 0">
|
|
|
+ and c.id not in
|
|
|
+ <foreach item="id" collection="inputIds" open="(" separator="," close=")">
|
|
|
+ #{id}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
UNION
|
|
|
SELECT a.`name` as retrieval_name,c.id as question_id,b.show_type FROM icss_retrieval a
|
|
|
LEFT JOIN icss_retrieval_mapping b ON a.id = b.retrieval_id
|
|
@@ -49,6 +55,12 @@
|
|
|
<if test="sexType != 3">
|
|
|
and c.sex_type in ('3',#{sexType})
|
|
|
</if>
|
|
|
+ <if test="inputIds != null and inputIds.size > 0">
|
|
|
+ and c.id not in
|
|
|
+ <foreach item="id" collection="inputIds" open="(" separator="," close=")">
|
|
|
+ #{id}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
UNION
|
|
|
SELECT a.`name` as retrieval_name,c.id as question_id,b.show_type FROM icss_retrieval a
|
|
|
LEFT JOIN icss_retrieval_mapping b ON a.id = b.retrieval_id
|
|
@@ -66,5 +78,11 @@
|
|
|
<if test="sexType != 3">
|
|
|
and c.sex_type in ('3',#{sexType})
|
|
|
</if>
|
|
|
+ <if test="inputIds != null and inputIds.size > 0">
|
|
|
+ and c.id not in
|
|
|
+ <foreach item="id" collection="inputIds" open="(" separator="," close=")">
|
|
|
+ #{id}
|
|
|
+ </foreach>
|
|
|
+ </if>
|
|
|
</select>
|
|
|
</mapper>
|