| | |
| | | <if test="id != '' and id != null"> |
| | | AND d.id like CONCAT('%',#{id},'%') |
| | | </if> |
| | | <choose> |
| | | <when test="excludeIds != null and excludeIds.size != 0"> |
| | | AND d.id NOT IN |
| | | <foreach collection="excludeIds" item="item" index="index" separator="," open="(" close=")"> |
| | | #{item} |
| | | </foreach> |
| | | </when> |
| | | </choose> |
| | | <if test="pageSize != '' and pageSize != null"> |
| | | limit #{pageSize} offset #{page}; |
| | | </if> |
| | |
| | | <if test="id != '' and id != null"> |
| | | AND ud.user_id = #{id} |
| | | </if> |
| | | <choose> |
| | | <when test="excludeIds != null and excludeIds.size != 0"> |
| | | AND d.id NOT IN |
| | | <foreach collection="excludeIds" item="item" index="index" separator="," open="(" close=")"> |
| | | #{item} |
| | | </foreach> |
| | | </when> |
| | | </choose> |
| | | </select> |
| | | |
| | | |