package com.wsm.admin.service;

import com.wsm.admin.model.Device;
import com.wsm.admin.model.DeviceEvent;
import com.wsm.common.service.IBaseService;

import java.util.Date;
import java.util.List;

public interface IDeviceEventService extends IBaseService<DeviceEvent, Long> {

    List<DeviceEvent> findByContentAndPostTime(String content, Date postTime);

    /**
     * 查询最新的一条
     * @param deviceId
     * @return
     */
    DeviceEvent findByDeviceIdTop(Long deviceId);

    DeviceEvent findByStatusAndDeviceId(Long deviceId, Integer status);
}
