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.StatsDevice;
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 StatsDeviceMapper extends BaseMapper<StatsDevice> {

    List<StatsDevice> selectDeviceStats(@Param("param") Map<String, Object> params);

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

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

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

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

    /**
     *设备今日统计总计
     * @param params
     * @return
     */
    PayOrderCount selectTodayStats4Device(@Param("param") Map<String, Object> params);

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