package com.ruoyi.project.ehs.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.ehs.mapper.TFirehydrantMapper;
import com.ruoyi.project.ehs.domain.TFirehydrant;
import com.ruoyi.project.ehs.service.ITFirehydrantService;

import javax.annotation.Resource;

/**
 * 消防栓Service业务层处理
 *
 * @author ruoyi
 * @date 2020-11-25
 */
@Service
public class TFirehydrantServiceImpl implements ITFirehydrantService
{
    @Resource
    private TFirehydrantMapper tFirehydrantMapper;

    /**
     * 查询消防栓
     *
     * @param id 消防栓ID
     * @return 消防栓
     */
    @Override
    public TFirehydrant selectTFirehydrantById(Long id)
    {
        return tFirehydrantMapper.selectTFirehydrantById(id);
    }

    /**
     * 查询消防栓列表
     *
     * @param tFirehydrant 消防栓
     * @return 消防栓
     */
    @Override
    public List<TFirehydrant> selectTFirehydrantList(TFirehydrant tFirehydrant)
    {
        return tFirehydrantMapper.selectTFirehydrantList(tFirehydrant);
    }

    /**
     * 定时任务查询消防栓列表
     *
     * @param tFirehydrant 消防栓
     * @return 消防栓集合
     */
    @Override
    public List<TFirehydrant> selectList(TFirehydrant tFirehydrant) {
        return tFirehydrantMapper.selectList(tFirehydrant);
    }

    /**
     * 新增消防栓
     *
     * @param tFirehydrant 消防栓
     * @return 结果
     */
    @Override
    public int insertTFirehydrant(TFirehydrant tFirehydrant)
    {
        return tFirehydrantMapper.insertTFirehydrant(tFirehydrant);
    }

    /**
     * 修改消防栓
     *
     * @param tFirehydrant 消防栓
     * @return 结果
     */
    @Override
    public int updateTFirehydrant(TFirehydrant tFirehydrant)
    {
        return tFirehydrantMapper.updateTFirehydrant(tFirehydrant);
    }

    /**
     * 批量删除消防栓
     *
     * @param ids 需要删除的消防栓ID
     * @return 结果
     */
    @Override
    public int deleteTFirehydrantByIds(Long[] ids)
    {
        return tFirehydrantMapper.deleteTFirehydrantByIds(ids);
    }

    /**
     * 删除消防栓信息
     *
     * @param id 消防栓ID
     * @return 结果
     */
    @Override
    public int deleteTFirehydrantById(Long id)
    {
        return tFirehydrantMapper.deleteTFirehydrantById(id);
    }
}
