package com.hzs.member.achieve.service;

import com.baomidou.mybatisplus.extension.service.IService;
import com.hzs.common.domain.member.achieve.CuMemberMonthAchieve;
import com.hzs.common.domain.member.ext.CuMemberMonthAchieveExt;
import com.hzs.member.achieve.controller.vo.MemberMonthAchieveVO;
import com.hzs.member.achieve.controller.vo.ParentAchieveVO;
import com.hzs.member.achieve.controller.vo.RealPerformanceVo;
import com.hzs.member.achieve.vo.CuMemberMonthVo;

import java.util.Date;
import java.util.List;

/**
 * <p>
 * 会员月数据 服务类
 * </p>
 *
 * @author hzs
 * @since 2023-06-06
 */
public interface ICuMemberMonthAchieveService extends IService<CuMemberMonthAchieve> {


    /*
     * @description: 每日生成业绩、月表统计数据
     * @author: sui q
     * @date: 2023/9/1 9:50
     * @param: null null
     **/
    void insertCuMemberAchieveByEveryDay(Date settleDate);

    /*
     * @description: 每天插入会员月表，计算推荐业绩，复购业绩，1-6号计算前7天
     * @author: sui q
     * @date: 2023/6/6 14:15
     * @param: null null
     **/
    void insertCuMemberMonthAchieve(Date settleDate);

    /*
     * @description: 每天统计月表数据
     * @author: sui q
     * @date: 2023/8/29 10:31
     * @param: null null
     **/
    void insertCuMemberCuMemberMonthYearAchieve(Date settleDate);

    /*
     * @description: 根据条件查询会员月业绩
     * @author: sui q
     * @date: 2023/6/7 16:00
     * @param: null null
     **/
    List<CuMemberMonthAchieveExt> queryCuMemberMonthAchieveRecommend(ParentAchieveVO parentAchieveVO);

    /*
     * @description: 根据条件查询会员月业绩 推荐达人
     * @author: sui q
     * @date: 2023/6/7 16:00
     * @param: null null
     **/
    List<CuMemberMonthAchieveExt> queryCuMemberMonthAchieveRepurchase(ParentAchieveVO parentAchieveVO);

    /**
     *
     * @param pkMember 会员主键
     * @param achieveTable 表名
     * @return
     */
    CuMemberMonthVo queryCuMemberMonthInfo(Long pkMember, String achieveTable);

    /**
     * 查询会员真实业绩
     * @param pkMember
     * @param achieveTable
     * @return
     */
    RealPerformanceVo queryCuMemberMonthAchieveInfo(Long pkMember, String achieveTable);
}
