字符串模糊查询
<if test="userName != null and userName!= ''">
AND `user_name` LIKE CONCAT(CONCAT('%', #{userName}), '%')
</if>
日期时间范围查询
<if test="dto.metaCreatedStart != null">
AND `meta_created` >= #{dto.metaCreatedStart}
</if>
<if test="dto.metaCreatedEnd != null">
AND `meta_created` <= #{dto.metaCreatedEnd}
</if>
集合范围查询
<if test="frameIds != null and frameIds.size> 0">
AND `frame_id ` IN (<foreach collection="frameIds" item="frameId" separator=","> #{frameId} </foreach>)
</if>
布尔类型查询
<if test="isNew != null and isNew == true">
AND `type` < 5
</if>