package com.srs.comprehensive.service.impl;

import java.util.List;
import com.srs.common.utils.DateUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.srs.comprehensive.mapper.SrsNotifyMapper;
import com.srs.comprehensive.domain.SrsNotify;
import com.srs.comprehensive.service.ISrsNotifyService;

/**
 * 新生报到通知Service业务层处理
 * 
 * @author srs
 * @date 2023-07-18
 */
@Service
public class SrsNotifyServiceImpl implements ISrsNotifyService 
{
    @Autowired
    private SrsNotifyMapper srsNotifyMapper;

    /**
     * 查询新生报到通知
     * 
     * @param id 新生报到通知主键
     * @return 新生报到通知
     */
    @Override
    public SrsNotify selectSrsNotifyById(Long id)
    {
        return srsNotifyMapper.selectSrsNotifyById(id);
    }

    /**
     * 查询新生报到通知列表
     * 
     * @param srsNotify 新生报到通知
     * @return 新生报到通知
     */
    @Override
    public List<SrsNotify> selectSrsNotifyList(SrsNotify srsNotify)
    {
        return srsNotifyMapper.selectSrsNotifyList(srsNotify);
    }

    /**
     * 新增新生报到通知
     * 
     * @param srsNotify 新生报到通知
     * @return 结果
     */
    @Override
    public int insertSrsNotify(SrsNotify srsNotify)
    {
        srsNotify.setCreateTime(DateUtils.getNowDate());
        return srsNotifyMapper.insertSrsNotify(srsNotify);
    }

    /**
     * 修改新生报到通知
     * 
     * @param srsNotify 新生报到通知
     * @return 结果
     */
    @Override
    public int updateSrsNotify(SrsNotify srsNotify)
    {
        srsNotify.setUpdateTime(DateUtils.getNowDate());
        return srsNotifyMapper.updateSrsNotify(srsNotify);
    }

    /**
     * 批量删除新生报到通知
     * 
     * @param ids 需要删除的新生报到通知主键
     * @return 结果
     */
    @Override
    public int deleteSrsNotifyByIds(Long[] ids)
    {
        return srsNotifyMapper.deleteSrsNotifyByIds(ids);
    }

    /**
     * 删除新生报到通知信息
     * 
     * @param id 新生报到通知主键
     * @return 结果
     */
    @Override
    public int deleteSrsNotifyById(Long id)
    {
        return srsNotifyMapper.deleteSrsNotifyById(id);
    }
}
