新增会员填充加入会员时间

This commit is contained in:
2024-09-25 16:46:55 +08:00
parent 4ab9490b45
commit e532174124
3 changed files with 27 additions and 4 deletions

View File

@@ -31,12 +31,13 @@
<result column="created_at" jdbcType="BIGINT" property="createdAt" />
<result column="updated_at" jdbcType="BIGINT" property="updatedAt" />
<result column="mini_open_id" jdbcType="VARCHAR" property="miniOpenId" />
<result column="join_time" jdbcType="VARCHAR" property="joinTime" />
</resultMap>
<sql id="Base_Column_List">
id, amount, credit_amount, consume_amount, consume_number, level_consume, status,
merchant_id, shop_id, user_id, parent_id, parent_level, name, head_img, sex, birth_day,
telephone, is_vip, code, is_attention, attention_at, is_shareholder, level, distribute_type,
sort, created_at, updated_at, mini_open_id,dynamic_code
sort, created_at, updated_at, mini_open_id,dynamic_code,join_time
</sql>
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
select
@@ -74,7 +75,7 @@
code, is_attention, attention_at,
is_shareholder, level, distribute_type,
sort, created_at, updated_at,
mini_open_id)
mini_open_id,join_time)
values (#{id,jdbcType=VARCHAR}, #{amount,jdbcType=DECIMAL}, #{creditAmount,jdbcType=DECIMAL},
#{consumeAmount,jdbcType=DECIMAL}, #{consumeNumber,jdbcType=INTEGER}, #{levelConsume,jdbcType=DECIMAL},
#{status,jdbcType=TINYINT}, #{merchantId,jdbcType=VARCHAR}, #{shopId,jdbcType=VARCHAR},
@@ -84,7 +85,7 @@
#{code,jdbcType=VARCHAR}, #{isAttention,jdbcType=TINYINT}, #{attentionAt,jdbcType=INTEGER},
#{isShareholder,jdbcType=TINYINT}, #{level,jdbcType=TINYINT}, #{distributeType,jdbcType=VARCHAR},
#{sort,jdbcType=INTEGER}, #{createdAt,jdbcType=BIGINT}, #{updatedAt,jdbcType=BIGINT},
#{miniOpenId,jdbcType=VARCHAR})
#{miniOpenId,jdbcType=VARCHAR},#{joinTime,jdbcType=TIMESTAMP})
</insert>
<insert id="insertSelective" parameterType="com.chaozhanggui.system.cashierservice.entity.TbShopUser">
insert into tb_shop_user
@@ -173,6 +174,9 @@
<if test="miniOpenId != null">
mini_open_id,
</if>
<if test="joinTime != null">
join_time,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
@@ -259,6 +263,9 @@
<if test="miniOpenId != null">
#{miniOpenId,jdbcType=VARCHAR},
</if>
<if test="joinTime != null">
#{joinTime,jdbcType=TIMESTAMP},
</if>
</trim>
</insert>
<update id="updateByPrimaryKeySelective" parameterType="com.chaozhanggui.system.cashierservice.entity.TbShopUser">
@@ -354,6 +361,9 @@
<if test="miniOpenId != null">
mini_open_id = #{miniOpenId,jdbcType=VARCHAR},
</if>
<if test="joinTime != null">
join_time = #{joinTime,jdbcType=TIMESTAMP},
</if>
</set>
where id = #{id,jdbcType=VARCHAR}
</update>
@@ -385,6 +395,7 @@
sort = #{sort,jdbcType=INTEGER},
created_at = #{createdAt,jdbcType=BIGINT},
updated_at = #{updatedAt,jdbcType=BIGINT},
join_time = #{joinTime,jdbcType=TIMESTAMP},
mini_open_id = #{miniOpenId,jdbcType=VARCHAR}
where id = #{id,jdbcType=VARCHAR}
</update>