<?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="shop.alien.mapper.LifeGroupBuyCountMapper">

    <resultMap id="BaseResultMap" type="shop.alien.entity.store.LifeGroupBuyCount">
            <id property="id" column="id" />
            <result property="countType" column="count_type" />
            <result property="storeId" column="store_id" />
            <result property="groupId" column="group_id" />
            <result property="userId" column="user_id" />
            <result property="countNum" column="count_num" />
            <result property="countDate" column="count_date" />
    </resultMap>

    <sql id="Base_Column_List">
        id,count_type,store_id,group_id,user_id,count_num,
        count_date
    </sql>

    <insert id="insertList" parameterType="java.util.List">
        INSERT INTO life_group_buy_count (
        id,
        count_type,
        store_id,
        group_id,
        user_id,
        count_num,
        count_date
        ) VALUES
        <foreach collection="list" item="item" separator=",">
            (
            #{item.id},
            #{item.countType},
            #{item.storeId},
            #{item.groupId},
            #{item.userId},
            #{item.countNum},
            #{item.countDate}
            )
        </foreach>
    </insert>

</mapper>
