From 558fd63b2fe4f5677e88b5e794fa072d5eb06856 Mon Sep 17 00:00:00 2001 From: zhuyiyi <649091362@qq.com> Date: Mon, 12 May 2025 10:16:18 +0800 Subject: [PATCH] edit --- .../java/lingtao/net/service/ProductService.java | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/src/main/java/lingtao/net/service/ProductService.java b/src/main/java/lingtao/net/service/ProductService.java index 5c75c34..bb009c4 100644 --- a/src/main/java/lingtao/net/service/ProductService.java +++ b/src/main/java/lingtao/net/service/ProductService.java @@ -535,14 +535,14 @@ public class ProductService { double huaxianPrice = 0.0; if (("0".equals(dto.getKindValue()) || "1".equals(dto.getKindValue())) && "划线".equals(dto.getCraftQieType())) { //宽度大于50 长度185-500 - if ("0".equals(dto.getKindValue())) { - if (!((width >= 5 && length >= 18.5 && length <= 500) || (length >= 5 && width >= 18.5 && width <= 500))) { - huaxianPrice = Math.max(0.13 * count, 50); - } - } else { - huaxianPrice = Math.max(0.26 * count, 50); - } for (Product product : stickersList) { + if ("0".equals(dto.getKindValue())) { + if (!((width >= 5 && length >= 18.5 && length <= 500) || (length >= 5 && width >= 18.5 && width <= 500))) { + huaxianPrice = Math.max(0.13 * product.getCount(), 50); + } + } else { + huaxianPrice = Math.max(0.26 * product.getCount(), 50); + } product.setPrice(Math.ceil(product.getPrice() + huaxianPrice)); } }