更新sql条件

This commit is contained in:
panshuling321 2022-01-26 15:39:12 +08:00
parent 80c82c68d3
commit 325e1a0300

View File

@ -54,13 +54,13 @@
LEFT JOIN xhpc_work_user u on o.user_id=u.work_user_id LEFT JOIN xhpc_work_user u on o.user_id=u.work_user_id
where o.del_flag=0 where o.del_flag=0
<if test="params.orderType != null and params.orderType != ''"> <if test="params.orderType != null and params.orderType != ''">
o.type=#{params.orderType} and o.type=#{params.orderType}
</if> </if>
<if test="params.userName!=null and params.userName!=''"> <if test="params.userName!=null and params.userName!=''">
u.user_name like concat ('%', #{params.userName}, '%') and u.user_name like concat ('%', #{params.userName}, '%')
</if> </if>
<if test="params.tenantId!=null and params.tenantId!=''"> <if test="params.tenantId!=null and params.tenantId!=''">
o.tenant_id = #{params.tenantId} and o.tenant_id = #{params.tenantId}
</if> </if>
</select> </select>