TASK:模块化;

This commit is contained in:
shahaibo
2025-03-31 15:27:17 +08:00
parent e6f990b766
commit 807d3e1c46

View File

@@ -596,17 +596,19 @@ public class CollectionElementServiceImpl extends ServiceImpl<CollectionElementM
} }
} }
// 校验模特 // 校验模特
if (designDTO.getModelType().equals(ModelType.LIBRARY.getValue())) { if (!StringUtils.isEmpty(designDTO.getModelType())) {
Library byId = libraryService.getById(designDTO.getTemplateId()); if (designDTO.getModelType().equals(ModelType.LIBRARY.getValue())) {
LibraryModelPoint modelPoint = libraryModelPointService.getByRelationId(byId.getId(), designDTO.getModelType()); Library byId = libraryService.getById(designDTO.getTemplateId());
elementVO.setDesignLibraryModelPoint(calculateTemplatePointTemplate(modelPoint, byId.getHigh(), byId.getWidth(), byId.getUrl())); LibraryModelPoint modelPoint = libraryModelPointService.getByRelationId(byId.getId(), designDTO.getModelType());
} else if (designDTO.getModelType().equals(ModelType.SYSTEM.getValue())) { elementVO.setDesignLibraryModelPoint(calculateTemplatePointTemplate(modelPoint, byId.getHigh(), byId.getWidth(), byId.getUrl()));
SysFileVO byId = sysFileService.getById(designDTO.getTemplateId()); } else if (designDTO.getModelType().equals(ModelType.SYSTEM.getValue())) {
if (!StringUtils.isEmpty(byId.getLevel3Type()) && byId.getLevel2Type().equals("Female")) { SysFileVO byId = sysFileService.getById(designDTO.getTemplateId());
elementVO.setStyle(byId.getLevel3Type()); if (!StringUtils.isEmpty(byId.getLevel3Type()) && byId.getLevel2Type().equals("Female")) {
elementVO.setStyle(byId.getLevel3Type());
}
LibraryModelPoint modelPoint = libraryModelPointService.getByRelationId(byId.getId(), designDTO.getModelType());
elementVO.setDesignLibraryModelPoint(calculateTemplatePointTemplate(modelPoint, 700, 320, byId.getUrl()));
} }
LibraryModelPoint modelPoint = libraryModelPointService.getByRelationId(byId.getId(), designDTO.getModelType());
elementVO.setDesignLibraryModelPoint(calculateTemplatePointTemplate(modelPoint, 700, 320, byId.getUrl()));
} }
elementVO.setModelSex(designDTO.getModelSex()); elementVO.setModelSex(designDTO.getModelSex());
elementVO.setRequestIdList(designDTO.getRequestIdList()); elementVO.setRequestIdList(designDTO.getRequestIdList());