会员 充值活动 奖励 赠送商品
This commit is contained in:
@@ -9,9 +9,10 @@
|
||||
<result column="handsel_num" jdbcType="DECIMAL" property="handselNum" />
|
||||
<result column="handsel_type" jdbcType="VARCHAR" property="handselType" />
|
||||
<result column="is_del" jdbcType="VARCHAR" property="isDel" />
|
||||
<result column="is_gift_pro" jdbcType="INTEGER" property="isGiftPro" />
|
||||
</resultMap>
|
||||
<sql id="Base_Column_List">
|
||||
id, shop_id, min_num, max_num, handsel_num, handsel_type, is_del
|
||||
id, shop_id, min_num, max_num, handsel_num, handsel_type, is_del,is_gift_pro
|
||||
</sql>
|
||||
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
||||
select
|
||||
@@ -116,10 +117,16 @@
|
||||
</update>
|
||||
|
||||
<select id="selectByAmount" resultMap="BaseResultMap">
|
||||
select * from tb_activate where shop_id=#{shopId} and is_del=0 and min_num <= #{amount} and max_num >= #{amount}
|
||||
</select>
|
||||
select *
|
||||
from tb_activate
|
||||
where shop_id = #{shopId}
|
||||
and is_del = 0
|
||||
and min_num <= #{amount}
|
||||
and max_num >= #{amount}
|
||||
order by max_num desc limit 1
|
||||
</select>
|
||||
|
||||
<select id="selectByShpopId" resultMap="BaseResultMap">
|
||||
<select id="selectByShopId" resultMap="BaseResultMap">
|
||||
select * from tb_activate where shop_id=#{shopId}
|
||||
</select>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user