package com.javaweb.platform.service.impl;
|
|
import java.util.List;
|
import com.javaweb.common.utils.DateUtils;
|
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.stereotype.Service;
|
import com.javaweb.platform.mapper.TestInfoMapper;
|
import com.javaweb.platform.domain.TestInfo;
|
import com.javaweb.platform.service.ITestInfoService;
|
import com.javaweb.common.core.text.Convert;
|
|
/**
|
* 测试记录Service业务层处理
|
*
|
* @author zzf
|
* @date 2022-03-25
|
*/
|
@Service
|
public class TestInfoServiceImpl implements ITestInfoService
|
{
|
@Autowired
|
private TestInfoMapper testInfoMapper;
|
|
/**
|
* 查询测试记录
|
*
|
* @param id 测试记录ID
|
* @return 测试记录
|
*/
|
@Override
|
public TestInfo selectTestInfoById(String id)
|
{
|
return testInfoMapper.selectTestInfoById(id);
|
}
|
|
/**
|
* 查询测试记录列表
|
*
|
* @param testInfo 测试记录
|
* @return 测试记录
|
*/
|
@Override
|
public List<TestInfo> selectTestInfoList(TestInfo testInfo)
|
{
|
return testInfoMapper.selectTestInfoList(testInfo);
|
}
|
|
/**
|
* 新增测试记录
|
*
|
* @param testInfo 测试记录
|
* @return 结果
|
*/
|
@Override
|
public int insertTestInfo(TestInfo testInfo)
|
{
|
testInfo.setCreateTime(DateUtils.getNowDate());
|
return testInfoMapper.insertTestInfo(testInfo);
|
}
|
|
/**
|
* 修改测试记录
|
*
|
* @param testInfo 测试记录
|
* @return 结果
|
*/
|
@Override
|
public int updateTestInfo(TestInfo testInfo)
|
{
|
testInfo.setUpdateTime(DateUtils.getNowDate());
|
return testInfoMapper.updateTestInfo(testInfo);
|
}
|
|
/**
|
* 删除测试记录对象
|
*
|
* @param ids 需要删除的数据ID
|
* @return 结果
|
*/
|
@Override
|
public int deleteTestInfoByIds(String ids)
|
{
|
return testInfoMapper.deleteTestInfoByIds(Convert.toStrArray(ids));
|
}
|
|
/**
|
* 删除测试记录信息
|
*
|
* @param id 测试记录ID
|
* @return 结果
|
*/
|
@Override
|
public int deleteTestInfoById(String id)
|
{
|
return testInfoMapper.deleteTestInfoById(id);
|
}
|
}
|