Merge branch 'dev/dev_xp' into dev/dev

This commit is contained in:
2025-06-17 16:56:45 +08:00

View File

@@ -409,7 +409,8 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
toProductImageRecordMapper.insert(toProductImageRecord); toProductImageRecordMapper.insert(toProductImageRecord);
List<ToProductImageResult> result = new ArrayList<>(); List<ToProductImageResult> result = new ArrayList<>();
boolean childFlag = !StringUtil.isNullOrEmpty(toProductImageDTO.getAgeGroup())
&& toProductImageDTO.getAgeGroup().equals("Child");
int i = 0; int i = 0;
// else { // else {
@@ -435,10 +436,14 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
productType = "single"; productType = "single";
sb.append(collect); sb.append(collect);
}else { }else {
if (collect.contains("Tops")) { if (collect.contains("Tops") && childFlag) {
sb.append("a handsome boy,");
}else if (collect.contains("Tops") && !childFlag){
sb.append("a handsome man,"); sb.append("a handsome man,");
}else if (childFlag) {
sb.append("a beautiful girl,");
}else { }else {
sb.append("a beautiful women,"); sb.append("a beautiful woman,");
} }
sb.append("wearing ").append(collect); sb.append("wearing ").append(collect);
} }
@@ -455,9 +460,8 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
toProductImageResult.setResultType("ToProductImage"); toProductImageResult.setResultType("ToProductImage");
} else { } else {
// 走模型 // 走模型
if (!StringUtil.isNullOrEmpty(toProductImageDTO.getAgeGroup()) if (childFlag){
&& toProductImageDTO.getAgeGroup().equals("Child")){ sb.append(", (Children's face:1.3)");
sb.append(", Children's face");
} }
pythonService.toProductImage(tDesignPythonOutfit.getDesignUrl(), taskId, sb.toString(), toProductImageDTO.getImageStrength(), productType); pythonService.toProductImage(tDesignPythonOutfit.getDesignUrl(), taskId, sb.toString(), toProductImageDTO.getImageStrength(), productType);
toProductImageResult.setModelName("local"); toProductImageResult.setModelName("local");
@@ -495,6 +499,10 @@ public class UserLikeGroupServiceImpl extends ServiceImpl<UserLikeGroupMapper, U
toProductImageResult.setModelName("flux"); toProductImageResult.setModelName("flux");
toProductImageResult.setResultType("ToProductImage"); toProductImageResult.setResultType("ToProductImage");
} else { } else {
// 走模型
if (childFlag){
sb.append(", (Children's face:1.3)");
}
// 走模型 // 走模型
pythonService.toProductImage(toProductElement.getUrl(), taskId, sb.toString(), toProductImageDTO.getImageStrength(), "overall"); pythonService.toProductImage(toProductElement.getUrl(), taskId, sb.toString(), toProductImageDTO.getImageStrength(), "overall");
toProductImageResult.setModelName("local"); toProductImageResult.setModelName("local");