wlzboy
2025-11-29 364adbc9a93a396b74e154f910c2a0a72bfb1a0f
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.payment.infrastructure.persistence.mapper.BizCallbackLogMapper">
 
    <resultMap id="BizCallbackLogResult" type="com.ruoyi.payment.domain.model.BizCallbackLog">
        <id property="id" column="id"/>
        <result property="orderId" column="order_id"/>
        <result property="transactionId" column="transaction_id"/>
        <result property="callbackUrl" column="callback_url"/>
        <result property="payload" column="payload"/>
        <result property="httpStatus" column="http_status"/>
        <result property="response" column="response"/>
        <result property="success" column="success"/>
        <result property="retryCount" column="retry_count"/>
        <result property="lastRetryAt" column="last_retry_at"/>
        <result property="createdAt" column="created_at"/>
    </resultMap>
 
    <insert id="insert" parameterType="com.ruoyi.payment.domain.model.BizCallbackLog">
        INSERT INTO pay_biz_callback_log (
            id, order_id, transaction_id, callback_url, payload,
            http_status, response, success, retry_count, last_retry_at, created_at
        ) VALUES (
            #{id}, #{orderId}, #{transactionId}, #{callbackUrl}, #{payload},
            #{httpStatus}, #{response}, #{success}, #{retryCount}, #{lastRetryAt}, #{createdAt}
        )
    </insert>
 
    <update id="update" parameterType="com.ruoyi.payment.domain.model.BizCallbackLog">
        UPDATE pay_biz_callback_log
        <set>
            <if test="orderId != null">order_id = #{orderId},</if>
            <if test="transactionId != null">transaction_id = #{transactionId},</if>
            <if test="callbackUrl != null">callback_url = #{callbackUrl},</if>
            <if test="payload != null">payload = #{payload},</if>
            <if test="httpStatus != null">http_status = #{httpStatus},</if>
            <if test="response != null">response = #{response},</if>
            <if test="success != null">success = #{success},</if>
            <if test="retryCount != null">retry_count = #{retryCount},</if>
            <if test="lastRetryAt != null">last_retry_at = #{lastRetryAt},</if>
        </set>
        WHERE id = #{id}
    </update>
 
    <select id="selectById" resultMap="BizCallbackLogResult">
        SELECT * FROM pay_biz_callback_log
        WHERE id = #{id}
    </select>
 
</mapper>