package com.hzs.activity.pick.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hzs.activity.pick.vo.AcPickMemberLogVO;
import com.hzs.common.domain.activity.pick.AcPickMemberLog;
import com.hzs.common.domain.activity.pick.ext.AcPickExt;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 会员提货记录 Mapper 接口
 */
public interface AcPickMemberLogMapper extends BaseMapper<AcPickMemberLog> {

    /**
     * 查询提货日志
     *
     * @param pkMember 会员ID
     * @return
     */
    List<AcPickMemberLogVO> queryMemberLog(@Param("pkMember") Long pkMember);

    /**
     * 批量插入提货日志
     *
     * @param acPickExtList 批量插入数据
     * @param quantity      插入数量
     * @param source        来源（1=后台，2=前台）
     * @return
     */
    int insertBatch(@Param("list") List<AcPickExt> acPickExtList,
                    @Param("quantity") Integer quantity,
                    @Param("source") Integer source);

    /*
     *  批量删除使用记录数据
     **/
    int deleteBatch(@Param("acPickMemberLogList") List<AcPickMemberLog> acPickMemberLogList);
}
