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.CmcContractWorkMapper;
import com.ruoyi.oa.domain.CmcContractWork;
import com.ruoyi.oa.service.ICmcContractWorkService;

/**
 * cmc合同内容Service业务层处理
 * 
 * @author cmc
 * @date 2024-04-19
 */
@Service
public class CmcContractWorkServiceImpl implements ICmcContractWorkService 
{
    @Autowired
    private CmcContractWorkMapper cmcContractWorkMapper;

    /**
     * 查询cmc合同内容
     * 
     * @param contractId cmc合同内容主键
     * @return cmc合同内容
     */
    @Override
    public List<CmcContractWork> selectCmcContractWorkByContractId(String contractId)
    {
        return cmcContractWorkMapper.selectCmcContractWorkByContractId(contractId);
    }

    /**
     * 查询cmc合同内容列表
     * 
     * @param cmcContractWork cmc合同内容
     * @return cmc合同内容
     */
    @Override
    public List<CmcContractWork> selectCmcContractWorkList(CmcContractWork cmcContractWork)
    {
        return cmcContractWorkMapper.selectCmcContractWorkList(cmcContractWork);
    }

    /**
     * 新增cmc合同内容
     * 
     * @param cmcContractWork cmc合同内容
     * @return 结果
     */
    @Override
    public int insertCmcContractWork(CmcContractWork cmcContractWork)
    {
        return cmcContractWorkMapper.insertCmcContractWork(cmcContractWork);
    }

    /**
     * 修改cmc合同内容
     * 
     * @param cmcContractWork cmc合同内容
     * @return 结果
     */
    @Override
    public int updateCmcContractWork(CmcContractWork cmcContractWork)
    {
        return cmcContractWorkMapper.updateCmcContractWork(cmcContractWork);
    }

    /**
     * 批量删除cmc合同内容
     * 
     * @param contractIds 需要删除的cmc合同内容主键
     * @return 结果
     */
    @Override
    public int deleteCmcContractWorkByContractIds(String[] contractIds)
    {
        return cmcContractWorkMapper.deleteCmcContractWorkByContractIds(contractIds);
    }

    /**
     * 删除cmc合同内容信息
     * 
     * @param contractId cmc合同内容主键
     * @return 结果
     */
    @Override
    public int deleteCmcContractWorkByContractId(String contractId)
    {
        return cmcContractWorkMapper.deleteCmcContractWorkByContractId(contractId);
    }
}
