package com.ruoyi.back.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.back.mapper.PdEnrolldataEnterProfessionMapper;
import com.ruoyi.back.domain.PdEnrolldataEnterProfession;
import com.ruoyi.back.service.IPdEnrolldataEnterProfessionService;

/**
 * 专业线Service业务层处理
 * 
 * @author voluntary
 * @date 2022-12-09
 */
@Service
public class PdEnrolldataEnterProfessionServiceImpl implements IPdEnrolldataEnterProfessionService 
{
    @Autowired
    private PdEnrolldataEnterProfessionMapper pdEnrolldataEnterProfessionMapper;

    /**
     * 查询专业线
     * 
     * @param id 专业线主键
     * @return 专业线
     */
    @Override
    public PdEnrolldataEnterProfession selectPdEnrolldataEnterProfessionById(String id)
    {
        return pdEnrolldataEnterProfessionMapper.selectPdEnrolldataEnterProfessionById(id);
    }

    /**
     * 查询专业线列表
     * 
     * @param pdEnrolldataEnterProfession 专业线
     * @return 专业线
     */
    @Override
    public List<PdEnrolldataEnterProfession> selectPdEnrolldataEnterProfessionList(PdEnrolldataEnterProfession pdEnrolldataEnterProfession)
    {
        return pdEnrolldataEnterProfessionMapper.selectPdEnrolldataEnterProfessionList(pdEnrolldataEnterProfession);
    }

    /**
     * 新增专业线
     * 
     * @param pdEnrolldataEnterProfession 专业线
     * @return 结果
     */
    @Override
    public int insertPdEnrolldataEnterProfession(PdEnrolldataEnterProfession pdEnrolldataEnterProfession)
    {
        pdEnrolldataEnterProfession.setCreateTime(DateUtils.getNowDate());
        return pdEnrolldataEnterProfessionMapper.insertPdEnrolldataEnterProfession(pdEnrolldataEnterProfession);
    }

    /**
     * 修改专业线
     * 
     * @param pdEnrolldataEnterProfession 专业线
     * @return 结果
     */
    @Override
    public int updatePdEnrolldataEnterProfession(PdEnrolldataEnterProfession pdEnrolldataEnterProfession)
    {
        pdEnrolldataEnterProfession.setUpdateTime(DateUtils.getNowDate());
        return pdEnrolldataEnterProfessionMapper.updatePdEnrolldataEnterProfession(pdEnrolldataEnterProfession);
    }

    /**
     * 批量删除专业线
     * 
     * @param ids 需要删除的专业线主键
     * @return 结果
     */
    @Override
    public int deletePdEnrolldataEnterProfessionByIds(String[] ids)
    {
        return pdEnrolldataEnterProfessionMapper.deletePdEnrolldataEnterProfessionByIds(ids);
    }

    /**
     * 删除专业线信息
     * 
     * @param id 专业线主键
     * @return 结果
     */
    @Override
    public int deletePdEnrolldataEnterProfessionById(String id)
    {
        return pdEnrolldataEnterProfessionMapper.deletePdEnrolldataEnterProfessionById(id);
    }
}
