Merge remote-tracking branch 'origin/develop' into develop

This commit is contained in:
shahaibo
2023-10-18 14:58:27 +08:00

View File

@@ -110,6 +110,14 @@ public class PanToneServiceImpl extends ServiceImpl<PanToneMapper, PanTone> impl
}
});
// 覆盖pantone中的rgb值,使用前端传过来的rgb值
for (Map.Entry<String, PantoneVO> pantoneVOEntry : colorPantoneVO.entrySet()) {
int[] rgb = Arrays.stream(pantoneVOEntry.getKey().split("\\s+")).mapToInt(Integer::parseInt).toArray();
pantoneVOEntry.getValue().setR(rgb[0]);
pantoneVOEntry.getValue().setG(rgb[1]);
pantoneVOEntry.getValue().setB(rgb[2]);
}
return colorPantoneVO;
}
@@ -164,9 +172,9 @@ public class PanToneServiceImpl extends ServiceImpl<PanToneMapper, PanTone> impl
return null;
}
PantoneVO pantoneVO = CopyUtil.copyObject(panTone,PantoneVO.class);
pantoneVO.setR(panTone.getR());
pantoneVO.setG(panTone.getG());
pantoneVO.setB(panTone.getB());
// pantoneVO.setR(panTone.getR());
// pantoneVO.setG(panTone.getG());
// pantoneVO.setB(panTone.getB());
pantoneVO.setId(panTone.getPantoneIndex());
return pantoneVO;
}