TASK:getDetail添加返回字段priority
This commit is contained in:
@@ -42,6 +42,9 @@ public class DesignItemClothesDetailVO {
|
|||||||
@ApiModelProperty("对应图层信息")
|
@ApiModelProperty("对应图层信息")
|
||||||
private List<DesignPythonOutfitVO> layersObject;
|
private List<DesignPythonOutfitVO> layersObject;
|
||||||
|
|
||||||
|
@ApiModelProperty("衣服所在图层")
|
||||||
|
private Integer priority;
|
||||||
|
|
||||||
public DesignItemClothesDetailVO() {
|
public DesignItemClothesDetailVO() {
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -1140,9 +1140,10 @@ public class DesignServiceImpl extends ServiceImpl<DesignMapper, Design> impleme
|
|||||||
designItemDetailVO.setDesignItemUrl(minioUtil.getPresignedUrl(designPythonOutfit.getDesignUrl(), 24 * 60));
|
designItemDetailVO.setDesignItemUrl(minioUtil.getPresignedUrl(designPythonOutfit.getDesignUrl(), 24 * 60));
|
||||||
// 2.1 填充clothes
|
// 2.1 填充clothes
|
||||||
designItemDetailVO.getClothes().forEach(c -> {
|
designItemDetailVO.getClothes().forEach(c -> {
|
||||||
String type = c.getType().toLowerCase();
|
// String type = c.getType().toLowerCase();
|
||||||
List<DesignPythonOutfitVO> outfitVOS = detailsVO.stream().filter(detail -> detail.getImageCategory().equals(type + "_back") ||
|
// List<DesignPythonOutfitVO> outfitVOS = detailsVO.stream().filter((detail -> detail.getImageCategory().equals(type + "_back") ||
|
||||||
detail.getImageCategory().equals(type + "_front")).collect(Collectors.toList());
|
// detail.getImageCategory().equals(type + "_front"))).collect(Collectors.toList());
|
||||||
|
List<DesignPythonOutfitVO> outfitVOS = detailsVO.stream().filter(detail -> detail.getPriority().equals(c.getPriority())).collect(Collectors.toList());
|
||||||
|
|
||||||
c.setLayersObject(outfitVOS);
|
c.setLayersObject(outfitVOS);
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user