<?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.yd.csf.service.dao.CommissionCompareRecordMapper">

    <resultMap id="BaseResultMap" type="com.yd.csf.service.model.CommissionCompareRecord">
            <id property="id" column="id" />
            <result property="commissionExpectedBizId" column="commission_expected_biz_id" />
            <result property="commissionBizId" column="commission_biz_id" />
            <result property="commissionPeriod" column="commission_period" />
            <result property="totalPeriod" column="total_period" />
            <result property="status" column="status" />
            <result property="currency" column="currency" />
            <result property="createTime" column="create_time" />
            <result property="exchangeRate" column="exchange_rate" />
            <result property="amount" column="amount" />
            <result property="currentCommissionRatio" column="current_commission_ratio" />
            <result property="operatorName" column="operator_name" />
            <result property="remark" column="remark" />
            <result property="isDeleted" column="is_deleted" />
    </resultMap>

    <sql id="Base_Column_List">
        id,commission_expected_biz_id,commission_biz_id,commission_period,total_period,status,
        currency,create_time,exchange_rate,amount,current_commission_ratio,operator_name,remark,
        is_deleted
    </sql>

    <delete id="removeByCommissionId">
        delete from commission_compare_record where commission_biz_id = #{commissionId}
    </delete>
</mapper>
