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.TMonthlyQualityReportS5003Mapper;
import com.ruoyi.project.production.domain.TMonthlyQualityReportS5003;
import com.ruoyi.project.production.service.ITMonthlyQualityReportS5003Service;

/**
 * 质量月报S5003Service业务层处理
 *
 * @author ruoyi
 * @date 2023-10-27
 */
@Service
public class TMonthlyQualityReportS5003ServiceImpl implements ITMonthlyQualityReportS5003Service
{
    @Autowired
    private TMonthlyQualityReportS5003Mapper tMonthlyQualityReportS5003Mapper;

    /**
     * 查询质量月报S5003
     *
     * @param id 质量月报S5003ID
     * @return 质量月报S5003
     */
    @Override
    public TMonthlyQualityReportS5003 selectTMonthlyQualityReportS5003ById(Long id)
    {
        return tMonthlyQualityReportS5003Mapper.selectTMonthlyQualityReportS5003ById(id);
    }

    /**
     * 查询质量月报S5003列表
     *
     * @param tMonthlyQualityReportS5003 质量月报S5003
     * @return 质量月报S5003
     */
    @Override
    public List<TMonthlyQualityReportS5003> selectTMonthlyQualityReportS5003List(TMonthlyQualityReportS5003 tMonthlyQualityReportS5003)
    {
        return tMonthlyQualityReportS5003Mapper.selectTMonthlyQualityReportS5003List(tMonthlyQualityReportS5003);
    }

    /**
     * 新增质量月报S5003
     *
     * @param tMonthlyQualityReportS5003 质量月报S5003
     * @return 结果
     */
    @Override
    public int insertTMonthlyQualityReportS5003(TMonthlyQualityReportS5003 tMonthlyQualityReportS5003)
    {
        tMonthlyQualityReportS5003.setCreateTime(DateUtils.getNowDate());
        return tMonthlyQualityReportS5003Mapper.insertTMonthlyQualityReportS5003(tMonthlyQualityReportS5003);
    }

    /**
     * 修改质量月报S5003
     *
     * @param tMonthlyQualityReportS5003 质量月报S5003
     * @return 结果
     */
    @Override
    public int updateTMonthlyQualityReportS5003(TMonthlyQualityReportS5003 tMonthlyQualityReportS5003)
    {
        tMonthlyQualityReportS5003.setUpdateTime(DateUtils.getNowDate());
        return tMonthlyQualityReportS5003Mapper.updateTMonthlyQualityReportS5003(tMonthlyQualityReportS5003);
    }

    /**
     * 批量删除质量月报S5003
     *
     * @param ids 需要删除的质量月报S5003ID
     * @return 结果
     */
    @Override
    public int deleteTMonthlyQualityReportS5003ByIds(Long[] ids)
    {
        return tMonthlyQualityReportS5003Mapper.deleteTMonthlyQualityReportS5003ByIds(ids);
    }

    /**
     * 删除质量月报S5003信息
     *
     * @param id 质量月报S5003ID
     * @return 结果
     */
    @Override
    public int deleteTMonthlyQualityReportS5003ById(Long id)
    {
        return tMonthlyQualityReportS5003Mapper.deleteTMonthlyQualityReportS5003ById(id);
    }
}
