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

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.pssr.mapper.TPssrVesselMapper;
import com.ruoyi.project.pssr.domain.TPssrVessel;
import com.ruoyi.project.pssr.service.ITPssrVesselService;

/**
 * 压力容器Service业务层处理
 *
 * @author ssy
 * @date 2024-11-07
 */
@Service
public class TPssrVesselServiceImpl implements ITPssrVesselService
{
    @Autowired
    private TPssrVesselMapper tPssrVesselMapper;

    /**
     * 查询压力容器
     *
     * @param id 压力容器ID
     * @return 压力容器
     */
    @Override
    public TPssrVessel selectTPssrVesselById(Long id)
    {
        return tPssrVesselMapper.selectTPssrVesselById(id);
    }

    @Override
    public int selectNoConfirmCount(Long subId)
    {
        return tPssrVesselMapper.selectNoConfirmCount(subId);
    }
    /**
     * 查询压力容器列表
     *
     * @param tPssrVessel 压力容器
     * @return 压力容器
     */
    @Override
    public List<TPssrVessel> selectTPssrVesselList(TPssrVessel tPssrVessel)
    {
        return tPssrVesselMapper.selectTPssrVesselList(tPssrVessel);
    }

    /**
     * 新增压力容器
     *
     * @param tPssrVessel 压力容器
     * @return 结果
     */
    @Override
    public int insertTPssrVessel(TPssrVessel tPssrVessel)
    {
        return tPssrVesselMapper.insertTPssrVessel(tPssrVessel);
    }

    /**
     * 修改压力容器
     *
     * @param tPssrVessel 压力容器
     * @return 结果
     */
    @Override
    public int updateTPssrVessel(TPssrVessel tPssrVessel)
    {
        return tPssrVesselMapper.updateTPssrVessel(tPssrVessel);
    }

    /**
     * 批量删除压力容器
     *
     * @param ids 需要删除的压力容器ID
     * @return 结果
     */
    @Override
    public int deleteTPssrVesselByIds(Long[] ids)
    {
        return tPssrVesselMapper.deleteTPssrVesselByIds(ids);
    }

    @Override
    public int updateTPssrVesselByIds(TPssrVessel vessel) {
        return tPssrVesselMapper.updateTPssrVesselByIds(vessel);
    }

    @Override
    public void deleteTPssrVesselBySubId(Long subId) {
        tPssrVesselMapper.deleteTPssrVesselBySubId(subId);
    }

    /**
     * 删除压力容器信息
     *
     * @param id 压力容器ID
     * @return 结果
     */
    @Override
    public int deleteTPssrVesselById(Long id)
    {
        return tPssrVesselMapper.deleteTPssrVesselById(id);
    }

    @Override
    public int updateAllBySubId(TPssrVessel vessel) {
        return tPssrVesselMapper.updateAllBySubId(vessel);}
}
