<?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.ruixuan.salesLeads.mapper.SaleFinancePolicyRebateInfoMapper">


<!-- 新增政策的返点比例-->
	<insert id="addSaleFinancePolicyRebateInfo">
		insert into sale_finance_policy_rebate_info(
			operation_time,
			quarter,
			rebate_rate,
			create_user_id,
			create_time
			)
		values
		(
			#{operationTime},
			#{quarter},
			#{rebateRate},
			#{createUserId},
			NOW()
		)
	</insert>

<!-- 查询最新的返点比例 -->
	<select id="selectFinacePolicyRebateInfo" resultType="com.ruixuan.salesLeads.pojo.SaleFinancePolicyRebateInfoPojo">
		SELECT
			*
		FROM
			`sale_finance_policy_rebate_info`
		ORDER BY
			create_time DESC
			LIMIT 1

	</select>





</mapper> 