package com.zioinfo.signage.mapper;

import com.zioinfo.signage.domain.AlarmVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.util.List;

@Mapper
public interface AlarmMapper {
    List<AlarmVo> findAll(@Param("tenantCode") String tenantCode,
                          @Param("storeId") Long storeId,
                          @Param("severity") String severity,
                          @Param("status") String status);
    AlarmVo findById(@Param("id") Long id);
    int insert(AlarmVo alarm);
    int update(AlarmVo alarm);
    int resolve(@Param("id") Long id, @Param("resolvedBy") String resolvedBy,
                @Param("resolution") String resolution);
    int delete(@Param("id") Long id);
    long countUnresolved(@Param("tenantCode") String tenantCode);
    long countCritical(@Param("tenantCode") String tenantCode);
    long countAll(@Param("tenantCode") String tenantCode);
}
