新增成本查询

This commit is contained in:
2026-06-27 16:58:17 +08:00
parent 79f0ae9e07
commit b55d238e5d
3 changed files with 18 additions and 39 deletions
@@ -618,32 +618,26 @@ public class PriceService {
if ("加厚铜版纸不干胶".equals(product.getKind())) {
basePrice = 2;
}
if ("黑胶铜版(遮盖/遮光)".equals(product.getKind())) {
basePrice = 4;
}
if ("牛皮纸".equals(product.getKind())) {
basePrice = 1.8;
}
if ("书写纸".equals(product.getKind())) {
basePrice = 1.8;
}
if ("易碎纸".equals(product.getKind())) {
List<String> base_4 = Arrays.asList("黑胶铜版(遮盖/遮光)", "易碎纸", "洒金宣纸(白色)", "亮银", "亮金");
if (base_4.contains(product.getKind())) {
basePrice = 4;
}
if ("洒金宣纸(白色)".equals(product.getKind())) {
basePrice = 4;
}
if ("超白浮雕纹".equals(product.getKind())) {
basePrice = 3.5;
}
if ("净白彩岩纹".equals(product.getKind())) {
List<String> base_3 = Arrays.asList("超白浮雕纹", "净白彩岩纹", "pp合成纸不干胶", "素面银镭射", "拉丝银", "拉丝金", "哑金");
if (base_3.contains(product.getKind())) {
basePrice = 3.5;
}
List<String> base_2 = Arrays.asList("艾丽铜板不干胶", "特光不干胶", "铜板可移不干胶", "大红洒金", "白布纹纸");
if (base_2.contains(product.getKind())) {
basePrice = 2.5;
}
basePrice = Math.max(2, basePrice);
// 计算一张纸能容纳的最大金属标数量
double maxItemsPerSheet = calculateMaxItemsPerSheet(length, width, paperLength, paperWidth);
@@ -678,7 +672,7 @@ public class PriceService {
return new PricingListVo(100, "超出纸张尺寸限制"); // 返回空列表表示不适用
}
List<String> list = Arrays.asList("300克双铜纸", "300克单铜白卡", "300克冰白卡纸", "300克荷兰白卡", "300克水晶磨砂", "300克铂金磨砂", "300克米黄荷兰白", "300克雅典米白灵感纸", "300克米黄丝绵纸", "325克素面镭射卡白底", "330克超白草香纸", "350克雅柔纸", "350克冰白卡纸", "350克荷兰白卡", "350克布纹", "350克蛋壳纹", "350克安格纹", "350克刚古纹", "350克米黄刚古纹", "350克米黄冰白", "350克超白超感纸", "雅柔毯纹超白");
int[] counts = new int[]{0, 5, 10, 20, 25, 50};
int[] counts = new int[]{1, 5, 10, 20, 25, 50};
double[] basePrices = new double[]{1.8, 9, 17, 34, 41.25, 82.5};
if ("300克单铜白卡".equals(product.getKind())) {
basePrices = new double[]{2, 10, 19, 38, 45, 90};
@@ -732,7 +726,6 @@ public class PriceService {
double basePrice = PriceUtils.TableCountDoublePrice(requiredSheets, basePrices, counts);
basePrice = Math.max(2.5, basePrice);
BigDecimal price = new BigDecimal(basePrice).multiply(new BigDecimal(requiredSheets)).setScale(2, RoundingMode.HALF_UP);
ProductVo pro = new ProductVo();
@@ -7517,7 +7517,7 @@ public class ProductService {
}
stickersList.add(new PriceUtils().getA(kind, length, width, count, price, addPrice, number, dto.getCraftTang(), dto.getYinbai()));
if (dto.getN_mq_num() != null && dto.getN_mq_num() >= 1) {
double base_price = 6 + 4;
double base_price = 5;
for (Product product : stickersList) {
product.setPrice(product.getPrice() + ((dto.getN_mq_num()) * base_price));