|
|
@@ -219,14 +219,16 @@ class CustomerTemplateService:
|
|
|
goods_art_no = product.get("货号",None)
|
|
|
goods_art_lens = len(new_config_data.get("货号资料", []))
|
|
|
concat_shuffix = "" if goods_art_lens == 1 else f"_{goods_art_no}"
|
|
|
- if not model_image:
|
|
|
- model_image = product.get("模特图", None)
|
|
|
- if model_image:
|
|
|
- self.copyImage(model_image, f"{scp_path}/模特图{concat_shuffix}.jpg")
|
|
|
- if not scene_image:
|
|
|
- scene_image = product.get("场景图", None)
|
|
|
- if scene_image:
|
|
|
- self.copyImage(scene_image, f"{scp_path}/场景图{concat_shuffix}.jpg")
|
|
|
+ if model_image is None:
|
|
|
+ model_image_path = product.get("模特图", None)
|
|
|
+ if model_image_path:
|
|
|
+ model_image = model_image_path
|
|
|
+ self.copyImage(model_image_path, f"{scp_path}/模特图{concat_shuffix}.jpg")
|
|
|
+ if scene_image is None:
|
|
|
+ scene_image_path = product.get("场景图", None)
|
|
|
+ if scene_image_path:
|
|
|
+ scene_image = scene_image_path
|
|
|
+ self.copyImage(scene_image_path, f"{scp_path}/场景图{concat_shuffix}.jpg")
|
|
|
new_pics = {}
|
|
|
for pic_key, pic_path in pics.items():
|
|
|
if "-抠图" in pic_key:
|