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.TMonthlyQualityReportS4501Mapper;
import com.ruoyi.project.production.domain.TMonthlyQualityReportS4501;
import com.ruoyi.project.production.service.ITMonthlyQualityReportS4501Service;

/**
 * 质量月报S4501Service业务层处理
 *
 * @author ruoyi
 * @date 2023-10-27
 */
@Service
public class TMonthlyQualityReportS4501ServiceImpl implements ITMonthlyQualityReportS4501Service
{
    @Autowired
    private TMonthlyQualityReportS4501Mapper tMonthlyQualityReportS4501Mapper;

    /**
     * 查询质量月报S4501
     *
     * @param id 质量月报S4501ID
     * @return 质量月报S4501
     */
    @Override
    public TMonthlyQualityReportS4501 selectTMonthlyQualityReportS4501ById(Long id)
    {
        return tMonthlyQualityReportS4501Mapper.selectTMonthlyQualityReportS4501ById(id);
    }

    /**
     * 查询质量月报S4501列表
     *
     * @param tMonthlyQualityReportS4501 质量月报S4501
     * @return 质量月报S4501
     */
    @Override
    public List<TMonthlyQualityReportS4501> selectTMonthlyQualityReportS4501List(TMonthlyQualityReportS4501 tMonthlyQualityReportS4501)
    {
        return tMonthlyQualityReportS4501Mapper.selectTMonthlyQualityReportS4501List(tMonthlyQualityReportS4501);
    }

    /**
     * 新增质量月报S4501
     *
     * @param tMonthlyQualityReportS4501 质量月报S4501
     * @return 结果
     */
    @Override
    public int insertTMonthlyQualityReportS4501(TMonthlyQualityReportS4501 tMonthlyQualityReportS4501)
    {
        tMonthlyQualityReportS4501.setCreateTime(DateUtils.getNowDate());
        return tMonthlyQualityReportS4501Mapper.insertTMonthlyQualityReportS4501(tMonthlyQualityReportS4501);
    }

    /**
     * 修改质量月报S4501
     *
     * @param tMonthlyQualityReportS4501 质量月报S4501
     * @return 结果
     */
    @Override
    public int updateTMonthlyQualityReportS4501(TMonthlyQualityReportS4501 tMonthlyQualityReportS4501)
    {
        tMonthlyQualityReportS4501.setUpdateTime(DateUtils.getNowDate());
        return tMonthlyQualityReportS4501Mapper.updateTMonthlyQualityReportS4501(tMonthlyQualityReportS4501);
    }

    /**
     * 批量删除质量月报S4501
     *
     * @param ids 需要删除的质量月报S4501ID
     * @return 结果
     */
    @Override
    public int deleteTMonthlyQualityReportS4501ByIds(Long[] ids)
    {
        return tMonthlyQualityReportS4501Mapper.deleteTMonthlyQualityReportS4501ByIds(ids);
    }

    /**
     * 删除质量月报S4501信息
     *
     * @param id 质量月报S4501ID
     * @return 结果
     */
    @Override
    public int deleteTMonthlyQualityReportS4501ById(Long id)
    {
        return tMonthlyQualityReportS4501Mapper.deleteTMonthlyQualityReportS4501ById(id);
    }
}
