package com.ruoyi.project.patrol.emergency.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.patrol.emergency.mapper.TEmergencyCabinetMapper;
import com.ruoyi.project.patrol.emergency.domain.TEmergencyCabinet;
import com.ruoyi.project.patrol.emergency.service.ITEmergencyCabinetService;

/**
 * 应急事故柜Service业务层处理
 * 
 * @author admin
 * @date 2023-11-07
 */
@Service
public class TEmergencyCabinetServiceImpl implements ITEmergencyCabinetService 
{
    @Autowired
    private TEmergencyCabinetMapper tEmergencyCabinetMapper;

    /**
     * 查询应急事故柜
     * 
     * @param id 应急事故柜主键
     * @return 应急事故柜
     */
    @Override
    public TEmergencyCabinet selectTEmergencyCabinetById(Long id)
    {
        return tEmergencyCabinetMapper.selectTEmergencyCabinetById(id);
    }

    /**
     * 查询应急事故柜列表
     * 
     * @param tEmergencyCabinet 应急事故柜
     * @return 应急事故柜
     */
    @Override
    public List<TEmergencyCabinet> selectTEmergencyCabinetList(TEmergencyCabinet tEmergencyCabinet)
    {
        return tEmergencyCabinetMapper.selectTEmergencyCabinetList(tEmergencyCabinet);
    }

    /**
     * 新增应急事故柜
     * 
     * @param tEmergencyCabinet 应急事故柜
     * @return 结果
     */
    @Override
    public int insertTEmergencyCabinet(TEmergencyCabinet tEmergencyCabinet)
    {
        return tEmergencyCabinetMapper.insertTEmergencyCabinet(tEmergencyCabinet);
    }

    /**
     * 修改应急事故柜
     * 
     * @param tEmergencyCabinet 应急事故柜
     * @return 结果
     */
    @Override
    public int updateTEmergencyCabinet(TEmergencyCabinet tEmergencyCabinet)
    {
        return tEmergencyCabinetMapper.updateTEmergencyCabinet(tEmergencyCabinet);
    }

    /**
     * 批量删除应急事故柜
     * 
     * @param ids 需要删除的应急事故柜主键
     * @return 结果
     */
    @Override
    public int deleteTEmergencyCabinetByIds(Long[] ids)
    {
        return tEmergencyCabinetMapper.deleteTEmergencyCabinetByIds(ids);
    }

    /**
     * 删除应急事故柜信息
     * 
     * @param id 应急事故柜主键
     * @return 结果
     */
    @Override
    public int deleteTEmergencyCabinetById(Long id)
    {
        return tEmergencyCabinetMapper.deleteTEmergencyCabinetById(id);
    }
}
