package com.ruoyi.oa.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.ruoyi.oa.mapper.CmcOutsourceMapper;
import com.ruoyi.oa.domain.CmcOutsource;
import com.ruoyi.oa.service.ICmcOutsourceService;

/**
 * 项目委外Service业务层处理
 * 
 * @author cmc
 * @date 2024-09-19
 */
@Service
public class CmcOutsourceServiceImpl implements ICmcOutsourceService 
{
    @Autowired
    private CmcOutsourceMapper cmcOutsourceMapper;

    /**
     * 查询项目委外
     * 
     * @param outsourceId 项目委外主键
     * @return 项目委外
     */
    @Override
    public CmcOutsource selectCmcOutsourceByOutsourceId(String outsourceId)
    {
        return cmcOutsourceMapper.selectCmcOutsourceByOutsourceId(outsourceId);
    }

    /**
     * 查询项目委外列表
     * 
     * @param cmcOutsource 项目委外
     * @return 项目委外
     */
    @Override
    public List<CmcOutsource> selectCmcOutsourceList(CmcOutsource cmcOutsource)
    {
        return cmcOutsourceMapper.selectCmcOutsourceList(cmcOutsource);
    }

    /**
     * 新增项目委外
     * 
     * @param cmcOutsource 项目委外
     * @return 结果
     */
    @Override
    public int insertCmcOutsource(CmcOutsource cmcOutsource)
    {
        return cmcOutsourceMapper.insertCmcOutsource(cmcOutsource);
    }

    /**
     * 修改项目委外
     * 
     * @param cmcOutsource 项目委外
     * @return 结果
     */
    @Override
    public int updateCmcOutsource(CmcOutsource cmcOutsource)
    {
        return cmcOutsourceMapper.updateCmcOutsource(cmcOutsource);
    }

    /**
     * 批量删除项目委外
     * 
     * @param outsourceIds 需要删除的项目委外主键
     * @return 结果
     */
    @Override
    public int deleteCmcOutsourceByOutsourceIds(String[] outsourceIds)
    {
        return cmcOutsourceMapper.deleteCmcOutsourceByOutsourceIds(outsourceIds);
    }

    /**
     * 删除项目委外信息
     * 
     * @param outsourceId 项目委外主键
     * @return 结果
     */
    @Override
    public int deleteCmcOutsourceByOutsourceId(String outsourceId)
    {
        return cmcOutsourceMapper.deleteCmcOutsourceByOutsourceId(outsourceId);
    }
}
