|
|
@ -26,15 +26,16 @@ |
|
|
LEFT JOIN market mk ON m.market = mk.id |
|
|
LEFT JOIN market mk ON m.market = mk.id |
|
|
<where> |
|
|
<where> |
|
|
m.flag = 0 |
|
|
m.flag = 0 |
|
|
<if test="status != null and status.size() > 0"> |
|
|
|
|
|
AND m.status IN |
|
|
|
|
|
<foreach item="item" collection="status" open="(" separator="," close=")"> |
|
|
|
|
|
|
|
|
<!-- 当 executor 不为 null 时,跳过 markets 过滤 --> |
|
|
|
|
|
<if test="executor == null and markets != null and markets.size() > 0"> |
|
|
|
|
|
AND m.market IN |
|
|
|
|
|
<foreach item="item" collection="markets" open="(" separator="," close=")"> |
|
|
#{item} |
|
|
#{item} |
|
|
</foreach> |
|
|
</foreach> |
|
|
</if> |
|
|
</if> |
|
|
<if test="markets != null and markets.size() > 0"> |
|
|
|
|
|
AND m.market IN |
|
|
|
|
|
<foreach item="item" collection="markets" open="(" separator="," close=")"> |
|
|
|
|
|
|
|
|
<if test="status != null and status.size() > 0"> |
|
|
|
|
|
AND m.status IN |
|
|
|
|
|
<foreach item="item" collection="status" open="(" separator="," close=")"> |
|
|
#{item} |
|
|
#{item} |
|
|
</foreach> |
|
|
</foreach> |
|
|
</if> |
|
|
</if> |
|
|
|