package com.ruoyi.web.service;

import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
import com.baomidou.mybatisplus.extension.service.IService;
import com.ruoyi.web.domain.dto.emergency.EmergencyAddRequest;
import com.ruoyi.web.domain.dto.emergency.EmergencyEditRequest;
import com.ruoyi.web.domain.dto.emergency.EmergencyQueryRequest;
import com.ruoyi.web.domain.dto.emergency.EmergencyRevokeRequest;
import com.ruoyi.web.domain.entity.Emergency;
import com.ruoyi.web.domain.vo.EmergencyVO;

/**
 *
 */
public interface EmergencyService extends IService<Emergency> {

    Integer addEmergency(EmergencyAddRequest emergencyAddRequest);

    boolean deleteEmergency(String ids);

    void editEmergency(EmergencyEditRequest emergencyEditRequest);

    /**
     * 撤回
     *
     * @param emergencyRevokeRequest
     */
    void revokeEmergency(EmergencyRevokeRequest emergencyRevokeRequest);

    /**
     * 下达
     *
     * @param emergencyRevokeRequest
     */
    void downEmergency(EmergencyRevokeRequest emergencyRevokeRequest);

    /**
     * 根据id查询
     *
     * @param id
     * @return
     */
    EmergencyVO getEmergencyById(int id);

    EmergencyVO getEmergencyVO(Emergency emergency);

    /**
     * 分页获取列表
     *
     * @param emergencyQueryRequest
     * @return
     */
    Page<EmergencyVO> getListEmergencyVOByPage(EmergencyQueryRequest emergencyQueryRequest);


    /**
     * 获取查询条件
     *
     * @param emergencyQueryRequest
     * @return
     */
    QueryWrapper<Emergency> getQueryWrapper(EmergencyQueryRequest emergencyQueryRequest);

}
