package com.microservices.pms.project.service.impl;

import com.microservices.pms.project.domain.PmsProjectTestReportSheet;
import com.microservices.pms.project.mapper.PmsProjectTestReportSheetMapper;
import com.microservices.pms.project.service.IPmsProjectTestReportSheetService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 测试报告-测试单关联Service业务层处理
 * 
 * @author wanjia
 * @date 2023-12-14
 */
@Service
public class PmsProjectTestReportSheetServiceImpl implements IPmsProjectTestReportSheetService 
{
    @Autowired
    private PmsProjectTestReportSheetMapper pmsProjectTestReportSheetMapper;

    /**
     * 查询测试报告-测试单关联
     * 
     * @param projectTestReportId 测试报告-测试单关联主键
     * @return 测试报告-测试单关联
     */
    @Override
    public List<PmsProjectTestReportSheet> selectPmsProjectTestReportSheetByProjectTestReportId(Long projectTestReportId)
    {
        return pmsProjectTestReportSheetMapper.selectPmsProjectTestReportSheetByProjectTestReportId(projectTestReportId);
    }

    /**
     * 查询测试报告-测试单关联列表
     * 
     * @param pmsProjectTestReportSheet 测试报告-测试单关联
     * @return 测试报告-测试单关联
     */
    @Override
    public List<PmsProjectTestReportSheet> selectPmsProjectTestReportSheetList(PmsProjectTestReportSheet pmsProjectTestReportSheet)
    {
        return pmsProjectTestReportSheetMapper.selectPmsProjectTestReportSheetList(pmsProjectTestReportSheet);
    }

    /**
     * 新增测试报告-测试单关联
     * 
     * @param pmsProjectTestReportSheet 测试报告-测试单关联
     * @return 结果
     */
    @Override
    public int insertPmsProjectTestReportSheet(PmsProjectTestReportSheet pmsProjectTestReportSheet)
    {
        return pmsProjectTestReportSheetMapper.insertPmsProjectTestReportSheet(pmsProjectTestReportSheet);
    }

    /**
     * 修改测试报告-测试单关联
     * 
     * @param pmsProjectTestReportSheet 测试报告-测试单关联
     * @return 结果
     */
    @Override
    public int updatePmsProjectTestReportSheet(PmsProjectTestReportSheet pmsProjectTestReportSheet)
    {
        return pmsProjectTestReportSheetMapper.updatePmsProjectTestReportSheet(pmsProjectTestReportSheet);
    }

    /**
     * 批量删除测试报告-测试单关联
     * 
     * @param projectTestReportIds 需要删除的测试报告-测试单关联主键
     * @return 结果
     */
    @Override
    public int deletePmsProjectTestReportSheetByProjectTestReportIds(Long[] projectTestReportIds)
    {
        return pmsProjectTestReportSheetMapper.deletePmsProjectTestReportSheetByProjectTestReportIds(projectTestReportIds);
    }

    /**
     * 删除测试报告-测试单关联信息
     * 
     * @param projectTestReportId 测试报告-测试单关联主键
     * @return 结果
     */
    @Override
    public int deletePmsProjectTestReportSheetByProjectTestReportId(Long projectTestReportId)
    {
        return pmsProjectTestReportSheetMapper.deletePmsProjectTestReportSheetByProjectTestReportId(projectTestReportId);
    }
}
