package com.hzs.bonus.bonus.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.hzs.common.domain.member.bonus.CuMemberBonusDetail;
import com.hzs.common.domain.member.ext.CuMemberBonusDetailExt;
import com.hzs.bonus.bonus.param.BonusParam;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 会员奖金-奖金收益明细表(报单费) Mapper 接口
 * </p>
 *
 * @author hzs
 * @since 2022-11-17
 */
public interface CuMemberBonusDetailMapper extends BaseMapper<CuMemberBonusDetail> {

    /**
     * 删除会员奖金汇总表
     * @param period 结算期间
     * @return: void
     * @Author: sui q
     * @Date: 2022/12/13 11:54
     */
    void deleteCuMemberBonusDetail(Integer period);

    /**
     * 批量插入会员奖金主表
     * @param cuMemberBonusDetailList 会员奖金
     * @return: void
     * @Author: sui q
     * @Date: 2022/12/13 13:56
     */
    void batchInsertCuMemberBonusDetail(@Param("cuMemberBonusDetailList") List<?> cuMemberBonusDetailList);

    /**
     * 批量插入会员奖金主表
     *
     * @param cuMemberBonusDetail 会员奖金
     * @return: void
     * @Author: sui q
     * @Date: 2022/12/13 13:56
     */
    void insertCuMemberBonusDetail(@Param("item") CuMemberBonusDetail cuMemberBonusDetail);

    /**
     * 根据查询条件查询会员奖金明细
     * @param bonusParam 查询条件
     * @return: List<CuMemberBonusDetail>
     * @Author: sui q
     * @Date: 2023/1/14 9:18
     */
    List<CuMemberBonusDetailExt> queryMemberBonusDetailByCondition(BonusParam bonusParam);


    /**
     * 会员端根据查询条件查询会员奖金明细
     * @param bonusParam 查询条件
     * @return: List<CuMemberBonusDetail>
     * @Author: sui q
     * @Date: 2023/1/14 9:18
     */
    List<CuMemberBonusDetailExt> queryMemberBonusDetailByConditionForServer(@Param("bonusParam") BonusParam bonusParam);
    /**
     * 根据查询条件查询固定的奖金明细
     * @param bonusParam 查询条件
    * @return: List<CuMemberBonusDetail>
    * @Author: sui q
    * @Date: 2023/1/14 11:18
    */
    List<CuMemberBonusDetailExt> queryMemberBonusDetailByBonusItems(BonusParam bonusParam);

    /**
     * 根据查询条件查询固定的奖金明细
     * @param bonusParam 查询条件
     * @return: List<CuMemberBonusDetail>
     * @Author: sui q
     * @Date: 2023/1/14 11:18
     */
    List<CuMemberBonusDetailExt> queryMemberBonusDetailByBonusItemsForServer(@Param("bonusParam") BonusParam bonusParam);
}
