<?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.kxs.store.biz.mapper.KxsWarehouseCreditAmountMapper">

    <resultMap type="com.kxs.store.api.model.KxsWarehouseCreditAmount" id="KxsWarehouseCreditAmountMap">
        <result column="id" property="id" />
        <result column="create_time" property="createTime" />
        <result column="update_time" property="updateTime" />
        <result column="del_flag" property="delFlag" />
        <result column="version" property="version" />
        <result column="status" property="status" />
        <result column="credit_user_id" property="creditUserId" />
        <result column="credit_amount" property="creditAmount" />
        <result column="to_credit_user_id" property="toCreditUserId" />
        <result column="username" property="username" />
        <result column="user_code" property="userCode" />
        <result column="create_by" property="createBy" />
        <result column="remark" property="remark" />

    </resultMap>
    <select id="selectByList" resultType="com.kxs.store.api.vo.kxsapp.storeCredit.StoreCreditListVO">
        select id, credit_user_id, credit_amount, username, user_code, create_time
        from kxs_warehouse_credit_amount
        <where>
            and del_flag = 0
            and status = 0
            and credit_user_id =  #{userId}
        </where>
    </select>

</mapper>
