feat:微信通知改造

This commit is contained in:
苏竹红
2025-10-14 19:02:09 +08:00
parent 28e1b860b1
commit 211fc19499
5 changed files with 66 additions and 0 deletions

View File

@@ -8,6 +8,8 @@
<result column="open_id" property="openId" jdbcType="VARCHAR" />
<result column="bind_time" property="bindTime" jdbcType="TIMESTAMP" />
<result column="partner_id" property="partnerId" jdbcType="VARCHAR" />
<result column="union_id" property="unionId" jdbcType="VARCHAR" />
<result column="service_account_open_id" property="serviceAccountOpenId" jdbcType="VARCHAR" />
<result column="create_time" property="createTime" jdbcType="TIMESTAMP" />
<result column="update_time" property="updateTime" jdbcType="TIMESTAMP" />
</resultMap>
@@ -17,15 +19,33 @@
open_id,
bind_time,
partner_id,
union_id,
create_time
) VALUES (
#{openId, jdbcType=VARCHAR},
#{bindTime, jdbcType=TIMESTAMP},
#{partnerId, jdbcType=VARCHAR},
#{unionId, jdbcType=VARCHAR},
#{createTime, jdbcType=TIMESTAMP}
)
</insert>
<update id="update" parameterType="com.cool.store.entity.PartnerUserWechatBindDO">
UPDATE xfsg_partner_user_wechat_bind
<set>
<if test="unionId != null">
union_id = #{unionId, jdbcType=VARCHAR},
</if>
where id = #{id}
</set>
</update>
<update id="updateByUnionId" >
UPDATE xfsg_partner_user_wechat_bind
set service_account_open_id = #{serviceAccountOpenId}
where union_id = #{unionId}
</update>
<select id="selectByPartnerAndOpenId" resultMap="BaseResultMap">
select * from xfsg_partner_user_wechat_bind where partner_id = #{partnerId} and open_id = #{openId}
</select>