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

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.project.training.mapper.TTrainingMatrixMapper;
import com.ruoyi.project.training.domain.TTrainingMatrix;
import com.ruoyi.project.training.service.ITTrainingMatrixService;

import javax.annotation.Resource;

/**
 * 培训矩阵Service业务层处理
 *
 * @author ruoyi
 * @date 2021-06-28
 */
@Service
public class TTrainingMatrixServiceImpl implements ITTrainingMatrixService
{
    @Resource
    private TTrainingMatrixMapper tTrainingMatrixMapper;

    /**
     * 查询培训矩阵
     *
     * @param id 培训矩阵ID
     * @return 培训矩阵
     */
    @Override
    public TTrainingMatrix selectTTrainingMatrixById(Long id)
    {
        return tTrainingMatrixMapper.selectTTrainingMatrixById(id);
    }

    /**
     * 查询培训矩阵列表
     *
     * @param tTrainingMatrix 培训矩阵
     * @return 培训矩阵
     */
    @Override
    public List<TTrainingMatrix> selectTTrainingMatrixList(TTrainingMatrix tTrainingMatrix)
    {
        return tTrainingMatrixMapper.selectTTrainingMatrixList(tTrainingMatrix);
    }

    /**
     * 新增培训矩阵
     *
     * @param tTrainingMatrix 培训矩阵
     * @return 结果
     */
    @Override
    public int insertTTrainingMatrix(TTrainingMatrix tTrainingMatrix)
    {
        return tTrainingMatrixMapper.insertTTrainingMatrix(tTrainingMatrix);
    }

    /**
     * 修改培训矩阵
     *
     * @param tTrainingMatrix 培训矩阵
     * @return 结果
     */
    @Override
    public int updateTTrainingMatrix(TTrainingMatrix tTrainingMatrix)
    {
        return tTrainingMatrixMapper.updateTTrainingMatrix(tTrainingMatrix);
    }

    /**
     * 批量删除培训矩阵
     *
     * @param ids 需要删除的培训矩阵ID
     * @return 结果
     */
    @Override
    public int deleteTTrainingMatrixByIds(Long[] ids)
    {
        return tTrainingMatrixMapper.deleteTTrainingMatrixByIds(ids);
    }

    /**
     * 删除培训矩阵信息
     *
     * @param id 培训矩阵ID
     * @return 结果
     */
    @Override
    public int deleteTTrainingMatrixById(Long id)
    {
        return tTrainingMatrixMapper.deleteTTrainingMatrixById(id);
    }
}
