<?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.hzs.system.config.mapper.BdTransferMapper">

    <!-- 通用查询映射结果 -->
    <resultMap id="BaseResultMap" type="com.hzs.common.domain.system.config.BdTransfer">
        <id column="PK_ID" property="pkId" />
    <result column="DEL_FLAG" property="delFlag" />
    <result column="PK_COUNTRY" property="pkCountry" />
    <result column="PK_CREATOR" property="pkCreator" />
    <result column="CREATION_TIME" property="creationTime" />
    <result column="PK_MODIFIED" property="pkModified" />
    <result column="MODIFIED_TIME" property="modifiedTime" />
        <result column="MIN_AMOUNT" property="minAmount" />
        <result column="IS_ROUNDING" property="isRounding" />
        <result column="IS_REFERENCE" property="isReference" />
        <result column="SERVICE_RATIO" property="serviceRatio" />
        <result column="EFFECTIVE_DATE" property="effectiveDate" />
    </resultMap>

    <!-- 通用查询结果列 -->
    <sql id="Base_Column_List">
        DEL_FLAG,
        PK_COUNTRY,
        PK_CREATOR,
        CREATION_TIME,
        PK_MODIFIED,
        MODIFIED_TIME,
        PK_ID, MIN_AMOUNT, IS_ROUNDING, IS_REFERENCE, SERVICE_RATIO, EFFECTIVE_DATE
    </sql>
     <!--查询会员是否有转账数据-->
    <select id="checkTransfer" parameterType="com.hzs.common.domain.system.config.BdTransfer"
            resultType="java.lang.Integer">
        select  count(1)  from cu_member_transfer where DEL_FLAG = 0
        <if test="pkCountry != null ">
            AND PK_COUNTRY = #{pkCountry}
        </if>
    </select>
</mapper>
