package cn.pluss.platform.fans;

import cn.pluss.platform.entity.Fans;
import cn.pluss.platform.vo.FansConsumVO;

import java.util.List;
import java.util.Map;

public interface FansService {

    public Fans queryFans(Fans fans);

    public List<Fans> queryFansList(Fans fans);

    public void saveFans(Fans fans);

    public void updateFans(Fans fans);

    public void deleteFans(Fans fans);

    public List<Fans> queryFansPage(Map map);

    public Integer queryFansPageCount(Map map);

    public Integer queryFansNoPageCount(Map map);

    public void saveFansBatch(List<Fans> fansList);
    
    /**
                  * 统计商户粉丝的交易总额
     * @param map
     * @return
     */
    public Double sumConsumMoneyByMerchantCode(Map<String, Object> map);
    
    /**
     * 
     * queryNowDateFansList:(获取当天粉丝的集合). <br/> 
     * 
     * @author Administrator 
     * @param map 
     * @return 
     * @since JDK 1.8
     */
    public List<Fans> queryNowDateFansList(Map map);
    
  public List<Fans> queryFansPageManage(Map map);
    
    public Integer queryFansPageCountManage(Map map);
    
    /**
     * 
     * queryLastFansByUserId:(查询某一粉丝最后一次消费的时间). <br/> 
     * 
     * @author Administrator 
     * @param userId
     * @return 
     * @since JDK 1.8
     */
    Fans queryLastFansByUserId(String userId);
    
    /**
     * 
     * queryFansConsumPage:(最新粉丝分润记录查询). <br/> 
     * 
     * @author Administrator 
     * @param map
     * @return 
     * @since JDK 1.8
     */
    public List<FansConsumVO> queryFansConsumPage(Map<String, Object> map);

    public List<FansConsumVO> queryFansNoConsumPage(Map<String, Object> map);
    
    /**
     * 
     * queryFansConsumPageCount:(最新粉丝分润记录统计). <br/> 
     * 
     * @author Administrator 
     * @param map
     * @return 
     * @since JDK 1.8
     */
    public Integer queryFansConsumPageCount(Map<String, Object> map);

    Integer queryFansNoConsumPageCount(Map<String, Object> map);
    
    Double queryFansSumConsumMoney(Map<String, Object> map);
    
    Double queryFansSumShareMoney(Map<String, Object> map);
    
    
    /**
     * 返回粉丝奖励总数
     * @param fans
     * @return
     */
    Double queryFansTodayCount(Fans fans);

	/**
	 * @description:根据订单号查询粉丝消费记录
	 * @date: 2021/9/1 13:32
	 * @param orderNumber:
	 * @return cn.pluss.platform.entity.Fans
	 */
    Fans getByLockOrderNumber(String orderNumber);
}

