package com.iailab.module.data.ind.data.service.impl; import com.iailab.framework.common.pojo.PageResult; import com.iailab.framework.common.service.impl.BaseServiceImpl; import com.iailab.framework.common.util.object.BeanUtils; import com.iailab.module.data.ind.category.entity.IndItemCategoryEntity; import com.iailab.module.data.ind.data.dao.IndDataSetDao; import com.iailab.module.data.ind.data.entity.IndDataSetEntity; import com.iailab.module.data.ind.data.service.IndDataSetService; import com.iailab.module.data.ind.data.vo.IndDataSetPageReqVO; import com.iailab.module.data.ind.data.vo.IndDataSetSaveReqVO; import org.springframework.stereotype.Service; import org.springframework.transaction.annotation.Transactional; import java.util.Date; import java.util.UUID; /** * @author PanZhibao * @Description * @createTime 2024年09月10日 */ @Service public class IndDataSetServiceImpl extends BaseServiceImpl implements IndDataSetService { @Override public PageResult page(IndDataSetPageReqVO reqVO) { return baseDao.selectPage(reqVO); } @Override public void create(IndDataSetSaveReqVO createReqVO) { IndDataSetEntity entity = BeanUtils.toBean(createReqVO, IndDataSetEntity.class); entity.setId(UUID.randomUUID().toString()); entity.setCreateTime(new Date()); baseDao.insert(entity); } @Override public void update(IndDataSetSaveReqVO updateReqVO) { IndDataSetEntity entity = BeanUtils.toBean(updateReqVO, IndDataSetEntity.class); entity.setUpdateTime(new Date()); baseDao.updateById(entity); } @Override public IndDataSetEntity get(String id) { return baseDao.selectById(id); } @Override public void delete(String id) { baseDao.deleteById(id); } }