/*
 * Copyright (c) 2018-2999 广州亚米信息科技有限公司 All rights reserved.
 *
 * https://www.gz-yami.com/
 *
 * 未经允许，不可做商业用途！
 *
 * 版权所有，侵权必究！
 */

package com.yami.shop.distribution.comment.service;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.yami.shop.bean.dto.OrderRefundDto;
import com.yami.shop.bean.model.OrderItem;
import com.yami.shop.common.util.PageParam;
import com.yami.shop.distribution.comment.dto.DistributionOrderDto;
import com.yami.shop.distribution.comment.dto.DistributionUserIncomeDto;
import com.yami.shop.distribution.comment.dto.DistributionUserIncomeOrderDto;
import com.yami.shop.distribution.comment.dto.StatisticsDisUserIncomeDto;
import com.yami.shop.distribution.comment.model.DistributionUserIncome;
import com.yami.shop.distribution.comment.param.RangeTimeParam;

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

/**
 * @author lgh on 2019/04/01.
 */
public interface DistributionUserIncomeService extends IService<DistributionUserIncome> {


    IPage<DistributionUserIncome> incomeAndDistributionUserPage(Page page, Long shopId, RangeTimeParam rangeTimeParam, String userMobile, String orderNumber, Integer state);


    /**
     * 获取分销员推广订单
     *
     * @return
     */
    IPage<DistributionOrderDto> getDistributionOrderDtoByDistributionUserId(Page page, Long distributionUserId);

    StatisticsDisUserIncomeDto statisticsDistributionUserIncome(Long distributionUserId);

    IPage<DistributionUserIncomeDto> getDistributionUserIncomePage(PageParam<DistributionUserIncome> page, Long distributionUserId);

    IPage<DistributionUserIncomeOrderDto> getMyPromotionOrderByState(PageParam<DistributionUserIncomeOrderDto> page, Long distributionUserId, Integer state);

    /**
     * 分销员佣金结算处理
     */
    void commissionSettlementHandle(Date date);

}
