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

import java.util.List;
import com.ruoyi.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.production.mapper.TFurnancePressureMapper;
import com.ruoyi.project.production.domain.TFurnancePressure;
import com.ruoyi.project.production.service.ITFurnancePressureService;

/**
 * 裂解炉炉管测压Service业务层处理
 *
 * @author ssy
 * @date 2024-03-21
 */
@Service
public class TFurnancePressureServiceImpl implements ITFurnancePressureService
{
    @Autowired
    private TFurnancePressureMapper tFurnancePressureMapper;

    /**
     * 查询裂解炉炉管测压
     *
     * @param id 裂解炉炉管测压ID
     * @return 裂解炉炉管测压
     */
    @Override
    public TFurnancePressure selectTFurnancePressureById(Long id)
    {
        return tFurnancePressureMapper.selectTFurnancePressureById(id);
    }

    /**
     * 查询裂解炉炉管测压列表
     *
     * @param tFurnancePressure 裂解炉炉管测压
     * @return 裂解炉炉管测压
     */
    @Override
    public List<TFurnancePressure> selectTFurnancePressureList(TFurnancePressure tFurnancePressure)
    {
        return tFurnancePressureMapper.selectTFurnancePressureList(tFurnancePressure);
    }

    /**
     * 查询裂解炉炉管测压
     *
     * @param tFurnancePressure 裂解炉炉管测压
     * @return 裂解炉炉管测压
     */
    public List<TFurnancePressure> selectTFurnancePressureByDate(TFurnancePressure tFurnancePressure) {
        return tFurnancePressureMapper.selectTFurnancePressureByDate(tFurnancePressure);
    }

    /**
     * 新增裂解炉炉管测压
     *
     * @param tFurnancePressure 裂解炉炉管测压
     * @return 结果
     */
    @Override
    public int insertTFurnancePressure(TFurnancePressure tFurnancePressure)
    {
        tFurnancePressure.setCreateTime(DateUtils.getNowDate());
        return tFurnancePressureMapper.insertTFurnancePressure(tFurnancePressure);
    }

    /**
     * 修改裂解炉炉管测压
     *
     * @param tFurnancePressure 裂解炉炉管测压
     * @return 结果
     */
    @Override
    public int updateTFurnancePressure(TFurnancePressure tFurnancePressure)
    {
        tFurnancePressure.setUpdateTime(DateUtils.getNowDate());
        return tFurnancePressureMapper.updateTFurnancePressure(tFurnancePressure);
    }

    /**
     * 批量删除裂解炉炉管测压
     *
     * @param ids 需要删除的裂解炉炉管测压ID
     * @return 结果
     */
    @Override
    public int deleteTFurnancePressureByIds(Long[] ids)
    {
        return tFurnancePressureMapper.deleteTFurnancePressureByIds(ids);
    }

    /**
     * 删除裂解炉炉管测压信息
     *
     * @param id 裂解炉炉管测压ID
     * @return 结果
     */
    @Override
    public int deleteTFurnancePressureById(Long id)
    {
        return tFurnancePressureMapper.deleteTFurnancePressureById(id);
    }
}
