Commit 02e50f2e authored by 李秀明's avatar 李秀明

fix: 修改错误SQL条件

parent e2311af4
...@@ -20,11 +20,16 @@ ...@@ -20,11 +20,16 @@
<if test="conditionColumn != null and conditionColumn != '' and conditionValue != null and conditionValue != ''"> <if test="conditionColumn != null and conditionColumn != '' and conditionValue != null and conditionValue != ''">
AND ${conditionColumn} = #{conditionValue} AND ${conditionColumn} = #{conditionValue}
</if> </if>
<if test="gatewayIds != null and gatewayIds.size() > 0"> <if test="gatewayIds != null">
AND GATEWAY_ID IN <if test="gatewayIds.size() > 0">
<foreach collection="gatewayIds" item="item" open="(" separator="," close=")"> AND GATEWAY_ID IN
${item} <foreach collection="gatewayIds" item="item" open="(" separator="," close=")">
</foreach> ${item}
</foreach>
</if>
<if test="gatewayIds.size() == 0">
AND 1 = 2
</if>
</if> </if>
GROUP BY GROUP BY
${column} ${column}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment