package vip.xiaonuo.coldchain.modular.app.service;

import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import lombok.RequiredArgsConstructor;
import org.springframework.stereotype.Service;
import vip.xiaonuo.coldchain.core.alarm.service.SensorAlarmService;
import vip.xiaonuo.coldchain.modular.app.param.Message;
import vip.xiaonuo.coldchain.modular.app.param.MessagePageParam;

import java.util.List;
import java.util.Map;

@Service
@RequiredArgsConstructor
public class MessageService {
    private final SensorAlarmService sensorAlarmService;

    // 获取未读消息的总数
    public Map<String, Long> getUnreadMessagesCount() {
        return null;
    }

    // 获取消息分页列表
    public Page<Message> getMessages(MessagePageParam messagePageParam) {
        return sensorAlarmService.getMessages(messagePageParam);
    }

    // 批量设置消息为已读
    public void markMessagesAsRead(List<Long> messageIds) {

    }
}
