package com.jcdm.main.bs.processes.service.impl;
|
|
import java.util.List;
|
import com.jcdm.common.utils.DateUtils;
|
import com.jcdm.main.bs.processes.domain.BsProcessesInfo;
|
import com.jcdm.main.bs.processes.mapper.BsProcessesInfoMapper;
|
import com.jcdm.main.bs.processes.service.IBsProcessesInfoService;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Service;
|
|
import static org.apache.commons.lang3.SystemUtils.getUserName;
|
|
/**
|
* 工序信息Service业务层处理
|
*
|
* @author ruimin
|
* @date 2023-12-09
|
*/
|
@Service
|
public class BsProcessesInfoServiceImpl implements IBsProcessesInfoService
|
{
|
@Autowired
|
private BsProcessesInfoMapper bsProcessesInfoMapper;
|
|
/**
|
* 查询工序信息
|
*
|
* @param id 工序信息主键
|
* @return 工序信息
|
*/
|
@Override
|
public BsProcessesInfo selectBsProcessesInfoById(Long id)
|
{
|
return bsProcessesInfoMapper.selectBsProcessesInfoById(id);
|
}
|
|
/**
|
* 查询工序信息列表
|
*
|
* @param bsProcessesInfo 工序信息
|
* @return 工序信息
|
*/
|
@Override
|
public List<BsProcessesInfo> selectBsProcessesInfoList(BsProcessesInfo bsProcessesInfo)
|
{
|
return bsProcessesInfoMapper.selectBsProcessesInfoList(bsProcessesInfo);
|
}
|
|
/**
|
* 新增工序信息
|
*
|
* @param bsProcessesInfo 工序信息
|
* @return 结果
|
*/
|
@Override
|
public int insertBsProcessesInfo(BsProcessesInfo bsProcessesInfo)
|
{
|
bsProcessesInfo.setCreateTime(DateUtils.getNowDate());
|
bsProcessesInfo.setCreateUser(getUserName());
|
return bsProcessesInfoMapper.insertBsProcessesInfo(bsProcessesInfo);
|
}
|
|
/**
|
* 修改工序信息
|
*
|
* @param bsProcessesInfo 工序信息
|
* @return 结果
|
*/
|
@Override
|
public int updateBsProcessesInfo(BsProcessesInfo bsProcessesInfo)
|
{
|
bsProcessesInfo.setUpdateTime(DateUtils.getNowDate());
|
bsProcessesInfo.setUpdateUser(getUserName());
|
return bsProcessesInfoMapper.updateBsProcessesInfo(bsProcessesInfo);
|
}
|
|
/**
|
* 批量删除工序信息
|
*
|
* @param ids 需要删除的工序信息主键
|
* @return 结果
|
*/
|
@Override
|
public int deleteBsProcessesInfoByIds(Long[] ids)
|
{
|
return bsProcessesInfoMapper.deleteBsProcessesInfoByIds(ids);
|
}
|
|
/**
|
* 删除工序信息信息
|
*
|
* @param id 工序信息主键
|
* @return 结果
|
*/
|
@Override
|
public int deleteBsProcessesInfoById(Long id)
|
{
|
return bsProcessesInfoMapper.deleteBsProcessesInfoById(id);
|
}
|
}
|