package com.ruoyi.system.service.impl;
|
|
import java.util.Date;
|
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.system.mapper.AiStudyBatchMapper;
|
import com.ruoyi.system.domain.AiStudyBatch;
|
import com.ruoyi.system.service.IAiStudyBatchService;
|
|
/**
|
* AI学习批次Service业务层处理
|
*
|
* @author ruoyi
|
* @date 2023-03-07
|
*/
|
@Service
|
public class AiStudyBatchServiceImpl implements IAiStudyBatchService
|
{
|
@Autowired
|
private AiStudyBatchMapper aiStudyBatchMapper;
|
|
/**
|
* 查询AI学习批次
|
*
|
* @param id AI学习批次主键
|
* @return AI学习批次
|
*/
|
@Override
|
public AiStudyBatch selectAiStudyBatchById(Long id)
|
{
|
return aiStudyBatchMapper.selectAiStudyBatchById(id);
|
}
|
|
/**
|
* 查询AI学习批次列表
|
*
|
* @param aiStudyBatch AI学习批次
|
* @return AI学习批次
|
*/
|
@Override
|
public List<AiStudyBatch> selectAiStudyBatchList(AiStudyBatch aiStudyBatch)
|
{
|
return aiStudyBatchMapper.selectAiStudyBatchList(aiStudyBatch);
|
}
|
|
/**
|
* 新增AI学习批次
|
*
|
* @param aiStudyBatch AI学习批次
|
* @return 结果
|
*/
|
@Override
|
public int insertAiStudyBatch(AiStudyBatch aiStudyBatch)
|
{
|
aiStudyBatch.setCreateTime(DateUtils.getNowDate());
|
return aiStudyBatchMapper.insertAiStudyBatch(aiStudyBatch);
|
}
|
|
/**
|
* 修改AI学习批次
|
*
|
* @param aiStudyBatch AI学习批次
|
* @return 结果
|
*/
|
@Override
|
public int updateAiStudyBatch(AiStudyBatch aiStudyBatch)
|
{
|
return aiStudyBatchMapper.updateAiStudyBatch(aiStudyBatch);
|
}
|
|
/**
|
* 批量删除AI学习批次
|
*
|
* @param ids 需要删除的数据主键集合
|
* @param userName 执行删除操作的用户名
|
* @param date 执行删除操作的时间
|
* @return 结果
|
*/
|
@Override
|
public int deleteAiStudyBatchByIds(Long[] ids, String userName, Date date)
|
{
|
return aiStudyBatchMapper.updateDelFlagByIds(ids,userName,date);
|
}
|
|
/**
|
* 逻辑删除AI学习批次信息
|
*
|
* @param id 需要删除的数据主键
|
* @param userName 执行删除操作的用户名
|
* @param date 执行删除操作的时间
|
* @return 结果
|
*/
|
@Override
|
public int deleteAiStudyBatchById(Long id , String userName, Date date)
|
{
|
|
return aiStudyBatchMapper.updateDelFlagById(id,userName,date);
|
}
|
}
|