package com.jeequan.jeepay.service.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.jeequan.jeepay.core.entity.PayOrderCount;
import com.jeequan.jeepay.db.entity.StatsChannel;
import org.apache.ibatis.annotations.Param;

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

/**
 * <p>
 * 通道数据统计表 Mapper 接口
 * </p>
 *
 * @author [mybatis plus generator]
 * @since 2022-12-20
 */
public interface StatsChannelMapper extends BaseMapper<StatsChannel> {

    List<StatsChannel> selectChannelStats(@Param("param") Map<String, Object> params);

    Long selectTodayTradeStatsCount(@Param("param") Map<String, Object> params);

    /**
     * 通道今日数据查询
     * @param params
     * @return
     */
    List<PayOrderCount> selectTodayTradeStatsList(@Param("param") Map<String, Object> params);

    /**
     * 通道非今日统计列表
     * @param params
     * @return
     */
    List<PayOrderCount> selectStatsList(@Param("param") Map<String, Object> params);

    /**
     * 通道今日统计总计
     * @param params
     * @return
     */
    PayOrderCount selectTodayStats4Channel(@Param("param") Map<String, Object> params);

    /**
     * 通道非今日统计总计
     * @param params
     * @return
     */
    PayOrderCount selectStats4Channel(@Param("param") Map<String, Object> params);
}
