package com.ruoyi.project.dc.thirdPartyTesting.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.project.dc.thirdPartyTesting.mapper.ThirdPartyTestingMapper; import com.ruoyi.project.dc.thirdPartyTesting.domain.ThirdPartyTesting; import com.ruoyi.project.dc.thirdPartyTesting.service.IThirdPartyTestingService; import com.ruoyi.common.utils.text.Convert; /** * 第三方检测Service业务层处理 * * @author wm * @date 2020-12-07 */ @Service public class ThirdPartyTestingServiceImpl implements IThirdPartyTestingService { @Autowired private ThirdPartyTestingMapper thirdPartyTestingMapper; /** * 查询第三方检测 * * @param testingId 第三方检测ID * @return 第三方检测 */ @Override public ThirdPartyTesting selectThirdPartyTestingById(Long testingId) { return thirdPartyTestingMapper.selectThirdPartyTestingById(testingId); } /** * 查询第三方检测列表 * * @param thirdPartyTesting 第三方检测 * @return 第三方检测 */ @Override public List selectThirdPartyTestingList(ThirdPartyTesting thirdPartyTesting) { return thirdPartyTestingMapper.selectThirdPartyTestingList(thirdPartyTesting); } /** * 新增第三方检测 * * @param thirdPartyTesting 第三方检测 * @return 结果 */ @Override public int insertThirdPartyTesting(ThirdPartyTesting thirdPartyTesting) { thirdPartyTesting.setCreateTime(DateUtils.getNowDate()); return thirdPartyTestingMapper.insertThirdPartyTesting(thirdPartyTesting); } /** * 修改第三方检测 * * @param thirdPartyTesting 第三方检测 * @return 结果 */ @Override public int updateThirdPartyTesting(ThirdPartyTesting thirdPartyTesting) { thirdPartyTesting.setUpdateTime(DateUtils.getNowDate()); return thirdPartyTestingMapper.updateThirdPartyTesting(thirdPartyTesting); } /** * 删除第三方检测对象 * * @param ids 需要删除的数据ID * @return 结果 */ @Override public int deleteThirdPartyTestingByIds(String ids) { return thirdPartyTestingMapper.deleteThirdPartyTestingByIds(Convert.toStrArray(ids)); } /** * 删除第三方检测信息 * * @param testingId 第三方检测ID * @return 结果 */ @Override public int deleteThirdPartyTestingById(Long testingId) { return thirdPartyTestingMapper.deleteThirdPartyTestingById(testingId); } }