<?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="cn.com.ctop.kuaishou.modules.report.mapper.KuaishouAgentAccountMapper">
    <insert id="replaceBatch">
        replace into ctop_kuaishou_agent_account(
        `id`,
        `user_id`,
        `account_name`,
        `balance`,
        `credit_balance`,
        `extended_balance`,
        `rebate`,
        `pre_rebate`,
        `contract_rebate`,
        `direct_rebate`,
        `total_balance`,
        `kuaibi_balance`,
        `push_balance`,
        `recharged`,
        `corporation_name`,
        `review_status`,
        `frozen_status`,
        `transfer_account_status`,
        `create_time`
        )
        values
        <foreach collection="list" item="agent" separator=",">
            (#{agent.id},
            #{agent.userId},
            #{agent.accountName},
            #{agent.balance},
            #{agent.creditBalance},
            #{agent.extendedBalance},
            #{agent.rebate},
            #{agent.preRebate},
            #{agent.contractRebate},
            #{agent.directRebate},
            #{agent.totalBalance},
            #{agent.kuaibiBalance},
            #{agent.pushBalance},
            #{agent.recharged},
            #{agent.corporationName},
            #{agent.reviewStatus},
            #{agent.frozenStatus},
            #{agent.transferAccountStatus},
            #{agent.createTime})
        </foreach>
    </insert>
</mapper>