package com.lutao.cloud.oil.mapper;

import com.lutao.cloud.common.data.datascope.CloudBaseMapper;
import com.lutao.cloud.oil.pojo.param.AlarmStatisticsParam;
import com.lutao.cloud.oil.pojo.param.TagAlarmQoqVOParam;
import com.lutao.cloud.oil.pojo.vo.AlarmStatisticByAppIdByTagType;
import com.lutao.cloud.oil.pojo.vo.TagAlarmClmPointVO;
import com.lutao.cloud.oil.pojo.vo.TagAlarmQoqListVO;
import com.lutao.cloud.oil.pojo.vo.TagProcessAlarmByUnit;
import com.lutao.entity.TagAlarmClm;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;

/**
 * 报警闭环
 *
 * @author yx
 * @date 2024/01/03
 */
@Mapper
public interface TagAlarmClmMapper extends CloudBaseMapper<TagAlarmClm> {


    /**
     * 报警闭环报警点位数量
     *
     * @return {@link List}<{@link TagAlarmClmPointVO}>
     */
    List<TagAlarmClmPointVO> selectTagAlarmClmPoint();

    /**
     * 火气今日报警数量
     *
     * @return {@link List}<{@link TagAlarmClmPointVO}>
     */
    List<TagAlarmClmPointVO> selectTagAlarmClmNumber();


    /**
     * 根据油商分组查询报警闭环数量
     *
     * @return {@link List}<{@link TagProcessAlarmByUnit}>
     */
    List<TagProcessAlarmByUnit> selectTagProcessAlarmByUnit(@Param("appId") String appId);

    /**
     * 火气今日销警数量
     *
     * @return {@link List}<{@link TagAlarmClmPointVO}>
     */
    List<TagAlarmClmPointVO>  selectTagAlarmClmCancelNumber();

    /**
     * 报警环比列表
     *
     * @param param 参数
     * @return {@link List }<{@link TagAlarmQoqListVO }>
     */
    List<TagAlarmQoqListVO> getTagAlarmQoqList(@Param("param") TagAlarmQoqVOParam param);


    /**
     * 按标签类型按app id统计报警
     *
     * @param param 参数
     * @return {@link List }<{@link AlarmStatisticByAppIdByTagType }>
     */
    List<AlarmStatisticByAppIdByTagType> alarmStatisticByAppIdByTagType(@Param("param") AlarmStatisticsParam param);
}
