package com.slodon.b2b2c.dao.read.statistics;

import com.slodon.b2b2c.core.database.BaseReadMapper;
import com.slodon.b2b2c.statistics.example.TerminalDayExample;
import com.slodon.b2b2c.statistics.pojo.TerminalDay;
import com.slodon.b2b2c.statistics.pojo.base.TerminalBase;
import com.slodon.b2b2c.vo.statistics.ChangeTrendVO;
import com.slodon.b2b2c.vo.statistics.SalesTrendVO;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 终端日统计表readDao
 */
public interface TerminalDayReadMapper extends BaseReadMapper<TerminalDay, TerminalDayExample> {

    /**
     * 终端统计
     *
     * @param example
     * @return
     */
    List<TerminalBase> getTerminalList(@Param("example") TerminalDayExample example);

    /**
     * 根据条件获取近30天变化趋势
     *
     * @param example
     * @return
     */
    List<ChangeTrendVO> getChangeTrendList(@Param("example") TerminalDayExample example);

    /**
     * 各终端销售变化趋势
     *
     * @param example
     * @return
     */
    List<SalesTrendVO> getTerminalTrendList(@Param("example") TerminalDayExample example);

    /**
     * 各终端销售占比
     *
     * @param example
     * @return
     */
    List<TerminalBase> getTerminalPercentList(@Param("example") TerminalDayExample example);
}