|
|
|
@@ -82,6 +82,28 @@ |
|
|
|
lm.discount |
|
|
|
</sql> |
|
|
|
|
|
|
|
<sql id="allCVoDynamicWhereConditions"> |
|
|
|
where 1 = 1 |
|
|
|
|
|
|
|
<if test=" null != tenantId "> |
|
|
|
and lm.tenant_id = #{tenantId} |
|
|
|
</if> |
|
|
|
|
|
|
|
<if test=" null != merchantId "> |
|
|
|
and lm.merchant_id = #{merchantId} |
|
|
|
</if> |
|
|
|
|
|
|
|
<if test=" null != levelId "> |
|
|
|
and lm.level_id = #{levelId} |
|
|
|
|
|
|
|
</if> |
|
|
|
|
|
|
|
<if test=" null != discount "> |
|
|
|
and lm.discount = #{discount} |
|
|
|
</if> |
|
|
|
|
|
|
|
<if test=" null != sortColumns"> order by ${sortColumns} </if> |
|
|
|
</sql> |
|
|
|
|
|
|
|
<select id="findListCVo" parameterType="com.iformall.domain.po.WxLevelMerchant" resultMap="CVoResultMap"> |
|
|
|
select <include refid="allCVoColumns" /> |
|
|
|
@@ -91,10 +113,7 @@ |
|
|
|
left join wx_shop s on ms.shop_id = s.id |
|
|
|
left join wx_mall_building mb on s.building = mb.id |
|
|
|
left join wx_mall_floor mf on s.floor = mf.id |
|
|
|
where 1=1 |
|
|
|
<if test=" null != levelId "> |
|
|
|
and `level_id` = #{levelId} |
|
|
|
</if> |
|
|
|
<include refid="allCVoDynamicWhereConditions" /> |
|
|
|
</select> |
|
|
|
|
|
|
|
</mapper> |