package com.huiju.estateagents.mapper;

import com.baomidou.mybatisplus.core.metadata.IPage;
import com.huiju.estateagents.entity.TsActivityDaily;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.huiju.estateagents.excel.ActivityDailyExport;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * <p>
 * 活动统计  Mapper 接口
 * </p>
 *
 * @author yansen
 * @since 2020-04-20
 */
@Mapper
public interface TsActivityDailyMapper extends BaseMapper<TsActivityDaily> {

    /**
     * 按天汇总活动统计信息
     * @param orgId
     * @param startDate
     * @param endDate
     * @param buildingId
     * @param targetType
     * @param targetId
     * @param targetName
     * @param asc
     * @param desc
     * @return
     */
    List<TsActivityDaily> getActivityDetail(@Param("orgId") Integer orgId,
                                             @Param("startDate") String startDate,
                                             @Param("endDate") String endDate,
                                             @Param("buildingId") String buildingId,
                                             @Param("targetType") String targetType,
                                             @Param("targetId") String targetId,
                                             @Param("targetName") String targetName,
                                             @Param("asc") String asc,
                                             @Param("desc") String desc);

    /**
     * 活动统计详情导出
     * @param orgId
     * @param startDate
     * @param endDate
     * @param buildingId
     * @param targetType
     * @param targetIdd
     * @return
     */
    List<ActivityDailyExport> getActivityExport(@Param("orgId") Integer orgId,
                                                @Param("startDate") String startDate,
                                                @Param("endDate") String endDate,
                                                @Param("buildingId") String buildingId,
                                                @Param("targetType") String targetType,
                                                @Param("targetId") String targetIdd);


}
