TASK:模块化;
This commit is contained in:
@@ -0,0 +1,7 @@
|
|||||||
|
package com.ai.da.mapper.primary;
|
||||||
|
|
||||||
|
import com.ai.da.common.config.mybatis.plus.CommonMapper;
|
||||||
|
import com.ai.da.mapper.primary.entity.ThreeDModule;
|
||||||
|
|
||||||
|
public interface ThreeDModuleMapper extends CommonMapper<ThreeDModule> {
|
||||||
|
}
|
||||||
@@ -0,0 +1,22 @@
|
|||||||
|
package com.ai.da.mapper.primary.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableName;
|
||||||
|
import lombok.Data;
|
||||||
|
import lombok.EqualsAndHashCode;
|
||||||
|
import lombok.experimental.Accessors;
|
||||||
|
|
||||||
|
import java.io.Serializable;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
@EqualsAndHashCode(callSuper = false)
|
||||||
|
@Accessors(chain = true)
|
||||||
|
@TableName("three_d_module")
|
||||||
|
public class ThreeDModule implements Serializable {
|
||||||
|
private static final long serialVersionUID = 1L;
|
||||||
|
@TableId(value = "id", type = IdType.AUTO)
|
||||||
|
private Long id;
|
||||||
|
private Long projectId;
|
||||||
|
private Long threeDSimpleId;
|
||||||
|
}
|
||||||
@@ -27,6 +27,8 @@ public class ModuleSaveDTO {
|
|||||||
@ApiModelProperty("手稿板图片id 数组")
|
@ApiModelProperty("手稿板图片id 数组")
|
||||||
private List<CollectionSketchDTO> sketchBoard;
|
private List<CollectionSketchDTO> sketchBoard;
|
||||||
|
|
||||||
|
private Long patternMaking3D;
|
||||||
|
|
||||||
// private MoodBoardModuleChooseVO moodBoard;
|
// private MoodBoardModuleChooseVO moodBoard;
|
||||||
// private List<CollectionElementVO> printBoard;
|
// private List<CollectionElementVO> printBoard;
|
||||||
// private List<CollectionColorVO> colorBoard;
|
// private List<CollectionColorVO> colorBoard;
|
||||||
|
|||||||
@@ -33,4 +33,6 @@ public class ModuleChooseVO {
|
|||||||
private List<PoseTransformationVO> poseTransfer;
|
private List<PoseTransformationVO> poseTransfer;
|
||||||
// private moodBoardModuleChooseVO patternMaking3D;
|
// private moodBoardModuleChooseVO patternMaking3D;
|
||||||
private SketchReconstructionVO deReconstruction;
|
private SketchReconstructionVO deReconstruction;
|
||||||
|
|
||||||
|
private ThreeDVO patternMaking3D;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -127,6 +127,8 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
|
|||||||
private ThreeDDetailMapper threeDDetailMapper;
|
private ThreeDDetailMapper threeDDetailMapper;
|
||||||
@Resource
|
@Resource
|
||||||
private ThreeDSimpleMapper threeDSimpleMapper;
|
private ThreeDSimpleMapper threeDSimpleMapper;
|
||||||
|
@Resource
|
||||||
|
private ThreeDModuleMapper threeDModuleMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public void deleteUserGroup(Long userGroupId) {
|
public void deleteUserGroup(Long userGroupId) {
|
||||||
@@ -1648,6 +1650,15 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
|
|||||||
}else if (module.equals(Module.poseTransfer.name())){
|
}else if (module.equals(Module.poseTransfer.name())){
|
||||||
List<PoseTransformationVO> poseTransformationResultList = generateService.getPoseTransformationResultList(projectDTO.getId());
|
List<PoseTransformationVO> poseTransformationResultList = generateService.getPoseTransformationResultList(projectDTO.getId());
|
||||||
moduleChooseVO.setPoseTransfer(poseTransformationResultList);
|
moduleChooseVO.setPoseTransfer(poseTransformationResultList);
|
||||||
|
}else if (module.equals(Module.patternMaking3D.name())) {
|
||||||
|
QueryWrapper<ThreeDModule> qw = new QueryWrapper<>();
|
||||||
|
qw.lambda().eq(ThreeDModule::getProjectId, projectDTO.getId());
|
||||||
|
List<ThreeDModule> threeDModules = threeDModuleMapper.selectList(qw);
|
||||||
|
if (CollectionUtil.isNotEmpty(threeDModules)) {
|
||||||
|
ThreeDModule threeDModule = threeDModules.get(0);
|
||||||
|
ThreeDVO patternMaking3D = getLayoutDetail(threeDModule.getThreeDSimpleId());
|
||||||
|
moduleChooseVO.setPatternMaking3D(patternMaking3D);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
return moduleChooseVO;
|
return moduleChooseVO;
|
||||||
@@ -1882,6 +1893,12 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
|
|||||||
collectionElementMapper.deleteBatchIds(old);
|
collectionElementMapper.deleteBatchIds(old);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
if (moduleSaveDTO.getPatternMaking3D() != null) {
|
||||||
|
ThreeDModule threeDModule = new ThreeDModule();
|
||||||
|
threeDModule.setProjectId(projectId);
|
||||||
|
threeDModule.setThreeDSimpleId(moduleSaveDTO.getPatternMaking3D());
|
||||||
|
threeDModuleMapper.insert(threeDModule);
|
||||||
|
}
|
||||||
if (boundingBox) {
|
if (boundingBox) {
|
||||||
QueryWrapper<CollectionElement> qw = new QueryWrapper<>();
|
QueryWrapper<CollectionElement> qw = new QueryWrapper<>();
|
||||||
qw.lambda().eq(CollectionElement::getLevel1Type, CollectionLevel1TypeEnum.SKETCH_BOARD.getRealName());
|
qw.lambda().eq(CollectionElement::getLevel1Type, CollectionLevel1TypeEnum.SKETCH_BOARD.getRealName());
|
||||||
|
|||||||
Reference in New Issue
Block a user