package com.elephant.framework.galaxy.aroad.module.emergencyevent.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.elephant.framework.galaxy.aroad.module.emergencyevent.entity.EmergencyEvent;
import org.apache.ibatis.annotations.Param;

/**
 * 应急事件表
 *
 * @author songwenjie
 * @date 2019-05-08 14:43:42
 */
public interface EmergencyEventMapper extends BaseMapper<EmergencyEvent> {

    /** 
    * @Description: 新增应急事件 
    * @param: [event]
    * @return: boolean 
    * @Author: songwenjie
    * @Date: 2019/5/15 
    */ 
    boolean saveEvent(EmergencyEvent event);


    /** 
    * @Description: 更新应急事件状态
    * @param: [enevtId, status]
    * @return: boolean 
    * @Author: songwenjie
    * @Date: 2019/5/15 
    */ 
    boolean updateStatus(@Param("eventId")Integer enevtId,@Param("status")String status);


    /** 
    * @Description: 分页获取应急事件
    * @param: [page, repotingDept]
    * @return: com.baomidou.mybatisplus.extension.plugins.pagination.Page<com.elephant.framework.galaxy.aroad.module.emergencyevent.entity.EmergencyEvent> 
    * @Author: songwenjie
    * @Date: 2019/5/15 
    */ 
    Page<EmergencyEvent> getEventPage (Page page,String reportingDept);
}
