|
@@ -10,7 +10,7 @@
|
|
|
<result column="group_id_" property="groupId"/>
|
|
|
</resultMap>
|
|
|
<sql id="Base_Column_List" >
|
|
|
- user_id_, used_count_, available_count_, available_amount_, modify_on_
|
|
|
+ user_id_, used_count_, available_count_, available_amount_, modify_on_,group_id_
|
|
|
</sql>
|
|
|
|
|
|
<select id="get" resultMap="BaseResultMap" parameterType="java.lang.Long" >
|
|
@@ -44,14 +44,17 @@
|
|
|
|
|
|
<insert id="insert" parameterType="com.ym.mec.biz.dal.entity.LuckDrawCount" >
|
|
|
insert into luck_draw_count (user_id_, used_count_, available_count_, available_amount_,
|
|
|
- modify_on_)
|
|
|
- values (#{userId,jdbcType=BIGINT}, #{usedCount,jdbcType=INTEGER}, #{availableCount,jdbcType=INTEGER}, #{availableAmount,jdbcType=BIGINT},
|
|
|
- #{modifyOn,jdbcType=TIMESTAMP})
|
|
|
+ modify_on_,group_id_)
|
|
|
+ values (#{userId}, #{usedCount}, #{availableCount}, #{availableAmount},
|
|
|
+ NOW(),#{groupId})
|
|
|
</insert>
|
|
|
|
|
|
<update id="update" parameterType="com.ym.mec.biz.dal.entity.LuckDrawCount" >
|
|
|
update luck_draw_count
|
|
|
<set >
|
|
|
+ <if test="groupId != null" >
|
|
|
+ group_id_ = #{groupId},
|
|
|
+ </if>
|
|
|
<if test="usedCount != null" >
|
|
|
used_count_ = #{usedCount,jdbcType=INTEGER},
|
|
|
</if>
|