package com.ruoyi.project.sems.his.service.impl;

import java.util.List;

import com.ruoyi.project.sems.domain.TSpecdevYlgd;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.sems.his.mapper.TSpechiYlgdMapper;
import com.ruoyi.project.sems.his.domain.TSpechiYlgd;
import com.ruoyi.project.sems.his.service.ITSpechiYlgdService;

/**
 * 特种设备压力管道台账历史Service业务层处理
 *
 * @author ruoyi
 * @date 2021-09-02
 */
@Service("tSpechiYlgdService")
public class TSpechiYlgdServiceImpl implements ITSpechiYlgdService
{
    @Autowired
    private TSpechiYlgdMapper tSpechiYlgdMapper;

    /**
     * 查询特种设备压力管道台账历史
     *
     * @param id 特种设备压力管道台账历史ID
     * @return 特种设备压力管道台账历史
     */
    @Override
    public TSpechiYlgd selectTSpechiYlgdById(Long id)
    {
        return tSpechiYlgdMapper.selectTSpechiYlgdById(id);
    }

    /**
     * 查询特种设备压力管道台账历史列表
     *
     * @param tSpechiYlgd 特种设备压力管道台账历史
     * @return 特种设备压力管道台账历史
     */
    @Override
    public List<TSpechiYlgd> selectTSpechiYlgdList(TSpechiYlgd tSpechiYlgd)
    {
        return tSpechiYlgdMapper.selectTSpechiYlgdList(tSpechiYlgd);
    }

    /**
     * 新增特种设备压力管道台账历史
     *
     * @param tSpechiYlgd 特种设备压力管道台账历史
     * @return 结果
     */
    @Override
    public int insertTSpechiYlgd(TSpechiYlgd tSpechiYlgd)
    {
        return tSpechiYlgdMapper.insertTSpechiYlgd(tSpechiYlgd);
    }

    /**
     * 使用台账对象新增特种设备压力管道台账历史
     * @param tSpecdevYlgd 特种设备压力管道台账
     * @return
     */
    @Override
    public int insertTSpechiYlgdWithDev(TSpecdevYlgd tSpecdevYlgd) {
        return tSpechiYlgdMapper.insertTSpechiYlgdByDev(tSpecdevYlgd);
    }

    /**
     * 修改特种设备压力管道台账历史
     *
     * @param tSpechiYlgd 特种设备压力管道台账历史
     * @return 结果
     */
    @Override
    public int updateTSpechiYlgd(TSpechiYlgd tSpechiYlgd)
    {
        return tSpechiYlgdMapper.updateTSpechiYlgd(tSpechiYlgd);
    }

    /**
     * 批量删除特种设备压力管道台账历史
     *
     * @param ids 需要删除的特种设备压力管道台账历史ID
     * @return 结果
     */
    @Override
    public int deleteTSpechiYlgdByIds(Long[] ids)
    {
        return tSpechiYlgdMapper.deleteTSpechiYlgdByIds(ids);
    }

    /**
     * 删除特种设备压力管道台账历史信息
     *
     * @param id 特种设备压力管道台账历史ID
     * @return 结果
     */
    @Override
    public int deleteTSpechiYlgdById(Long id)
    {
        return tSpechiYlgdMapper.deleteTSpechiYlgdById(id);
    }

    @Override
    public List<TSpechiYlgd> selectTSpechiYlgdByReform(Long devId) {
        return tSpechiYlgdMapper.selectTSpechiYlgdByReform(devId);
    }

    /**
     * 通过devId删除修改记录
     * @param devId
     * @return
     */
    @Override
    public int deleteTSpechiYlgdByDevId(Long devId) {
        return tSpechiYlgdMapper.deleteTSpechiYlgdByDevId(devId);
    }
}
