筛选不全的bug
This commit is contained in:
@@ -17,9 +17,11 @@
|
|||||||
AND so.buyer_id = #{dto.buyerId}
|
AND so.buyer_id = #{dto.buyerId}
|
||||||
AND so.status = 1
|
AND so.status = 1
|
||||||
<if test="dto.categories != null and dto.categories.size() > 0">
|
<if test="dto.categories != null and dto.categories.size() > 0">
|
||||||
<foreach collection="dto.categories" item="cat">
|
AND (
|
||||||
AND JSON_CONTAINS(soi.product_category, #{cat})
|
<foreach collection="dto.categories" item="cat" separator=" OR ">
|
||||||
|
JSON_CONTAINS(soi.product_category, #{cat})
|
||||||
</foreach>
|
</foreach>
|
||||||
|
)
|
||||||
</if>
|
</if>
|
||||||
<if test="dto.designFor != null and dto.designFor != '' and dto.designFor != 'all'">
|
<if test="dto.designFor != null and dto.designFor != '' and dto.designFor != 'all'">
|
||||||
AND l.design_for = #{dto.designFor}
|
AND l.design_for = #{dto.designFor}
|
||||||
@@ -38,9 +40,11 @@
|
|||||||
AND so.buyer_id = #{dto.buyerId}
|
AND so.buyer_id = #{dto.buyerId}
|
||||||
AND so.status = 1
|
AND so.status = 1
|
||||||
<if test="dto.categories != null and dto.categories.size() > 0">
|
<if test="dto.categories != null and dto.categories.size() > 0">
|
||||||
<foreach collection="dto.categories" item="cat">
|
AND (
|
||||||
AND JSON_CONTAINS(soi.product_category, #{cat})
|
<foreach collection="dto.categories" item="cat" separator=" OR ">
|
||||||
|
JSON_CONTAINS(soi.product_category, #{cat})
|
||||||
</foreach>
|
</foreach>
|
||||||
|
)
|
||||||
</if>
|
</if>
|
||||||
<if test="dto.designFor != null and dto.designFor != '' and dto.designFor != 'all'">
|
<if test="dto.designFor != null and dto.designFor != '' and dto.designFor != 'all'">
|
||||||
AND l.design_for = #{dto.designFor}
|
AND l.design_for = #{dto.designFor}
|
||||||
|
|||||||
Reference in New Issue
Block a user