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.TMonthlyQualityReportS3012Mapper;
import com.ruoyi.project.production.domain.TMonthlyQualityReportS3012;
import com.ruoyi.project.production.service.ITMonthlyQualityReportS3012Service;

/**
 * 质量月报S3012Service业务层处理
 *
 * @author ruoyi
 * @date 2023-10-27
 */
@Service
public class TMonthlyQualityReportS3012ServiceImpl implements ITMonthlyQualityReportS3012Service
{
    @Autowired
    private TMonthlyQualityReportS3012Mapper tMonthlyQualityReportS3012Mapper;

    /**
     * 查询质量月报S3012
     *
     * @param id 质量月报S3012ID
     * @return 质量月报S3012
     */
    @Override
    public TMonthlyQualityReportS3012 selectTMonthlyQualityReportS3012ById(Long id)
    {
        return tMonthlyQualityReportS3012Mapper.selectTMonthlyQualityReportS3012ById(id);
    }

    /**
     * 查询质量月报S3012列表
     *
     * @param tMonthlyQualityReportS3012 质量月报S3012
     * @return 质量月报S3012
     */
    @Override
    public List<TMonthlyQualityReportS3012> selectTMonthlyQualityReportS3012List(TMonthlyQualityReportS3012 tMonthlyQualityReportS3012)
    {
        return tMonthlyQualityReportS3012Mapper.selectTMonthlyQualityReportS3012List(tMonthlyQualityReportS3012);
    }

    /**
     * 新增质量月报S3012
     *
     * @param tMonthlyQualityReportS3012 质量月报S3012
     * @return 结果
     */
    @Override
    public int insertTMonthlyQualityReportS3012(TMonthlyQualityReportS3012 tMonthlyQualityReportS3012)
    {
        tMonthlyQualityReportS3012.setCreateTime(DateUtils.getNowDate());
        return tMonthlyQualityReportS3012Mapper.insertTMonthlyQualityReportS3012(tMonthlyQualityReportS3012);
    }

    /**
     * 修改质量月报S3012
     *
     * @param tMonthlyQualityReportS3012 质量月报S3012
     * @return 结果
     */
    @Override
    public int updateTMonthlyQualityReportS3012(TMonthlyQualityReportS3012 tMonthlyQualityReportS3012)
    {
        tMonthlyQualityReportS3012.setUpdateTime(DateUtils.getNowDate());
        return tMonthlyQualityReportS3012Mapper.updateTMonthlyQualityReportS3012(tMonthlyQualityReportS3012);
    }

    /**
     * 批量删除质量月报S3012
     *
     * @param ids 需要删除的质量月报S3012ID
     * @return 结果
     */
    @Override
    public int deleteTMonthlyQualityReportS3012ByIds(Long[] ids)
    {
        return tMonthlyQualityReportS3012Mapper.deleteTMonthlyQualityReportS3012ByIds(ids);
    }

    /**
     * 删除质量月报S3012信息
     *
     * @param id 质量月报S3012ID
     * @return 结果
     */
    @Override
    public int deleteTMonthlyQualityReportS3012ById(Long id)
    {
        return tMonthlyQualityReportS3012Mapper.deleteTMonthlyQualityReportS3012ById(id);
    }
}
