From 6e785f1e61ba61743b37bc0d2c3db7fd858bb761 Mon Sep 17 00:00:00 2001 From: zhuyiyi <649091362@qq.com> Date: Fri, 25 Jul 2025 09:43:07 +0800 Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E6=B0=B4=E6=A0=87=E4=BB=B7?= =?UTF-8?q?=E6=A0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../lingtao/net/service/ProductService.java | 64 +++- src/main/webapp/views/product/pet.jsp | 4 +- src/main/webapp/views/product/waterGauge.jsp | 330 ++++++++++++++++++ 3 files changed, 395 insertions(+), 3 deletions(-) create mode 100644 src/main/webapp/views/product/waterGauge.jsp diff --git a/src/main/java/lingtao/net/service/ProductService.java b/src/main/java/lingtao/net/service/ProductService.java index 74c1ddc..4f092fb 100644 --- a/src/main/java/lingtao/net/service/ProductService.java +++ b/src/main/java/lingtao/net/service/ProductService.java @@ -4763,13 +4763,75 @@ public class ProductService { area = length * width; return getAreaCenterPrice(count_list, count, area, prices, areas, number); + case "水标": + return getShuibiaoPrice(dto, length, width); default: break; } return null; } - private List getAreaCenterPrice(int[] count_list, int count, double area, int[][] prices, double[] areas, int number) { + private List getShuibiaoPrice(Product dto, double length, double width) { + List craft_list = dto.getCraft() == null ? new ArrayList<>() : Arrays.asList(dto.getCraft()); + int count = dto.getCount(); + int number = dto.getNumber(); + int[][] prices = new int[][]{}; + if (craft_list.size() > 0) { + if (craft_list.contains("单面") && craft_list.contains("亮膜")) { + prices = new int[][]{ + {387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 400}, + {387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 405}, + {387, 387, 387, 387, 387, 387, 387, 420, 470, 524, 577, 634, 697, 757}, + {387, 387, 400, 470, 540, 624, 710, 797, 894, 1000, 1107, 1224, 1344, 1470}, + {387, 487, 580, 680, 790, 910, 1040, 1177, 1324, 1477, 1640, 1494, 1640, 1794}, + {517, 780, 937, 1104, 1290, 1487, 1700, 1587, 1787, 1997, 2220, 2454, 2700, 2960}, + {987, 1520, 1504, 1780, 2084, 2404, 2757, 3130, 3527, 3950, 4394, 4864, 5357, 5877}, + }; + } + if (craft_list.contains("双面") && craft_list.contains("亮膜")) { + prices = new int[][]{ + {720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720}, + {720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720, 720}, + {720, 720, 720, 720, 720, 720, 720, 720, 724, 724, 734, 807, 884, 967}, + {720, 720, 720, 724, 724, 790, 904, 1020, 1144, 1277, 1417, 1567, 1724, 1887}, + {720, 724, 737, 864, 1007, 1167, 1330, 1507, 1694, 1897, 2107, 1944, 2137, 2340}, + {724, 994, 1197, 1414, 1654, 1910, 2187, 2070, 2330, 2607, 2900, 3207, 3530, 3874}, + {1264, 1947, 1960, 2320, 2717, 3144, 3604, 4094, 4617, 5167, 5754, 6370, 7020, 7700}, + + }; + } + if (craft_list.contains("单面") && craft_list.contains("哑膜")) { + prices = new int[][]{ + {387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387}, + {387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 387, 404}, + {387, 387, 387, 387, 387, 387, 387, 427, 477, 527, 584, 640, 704, 767}, + {387, 387, 404, 474, 547, 630, 717, 810, 904, 1010, 1120, 1237, 1357, 1487}, + {387, 494, 587, 687, 800, 924, 1054, 1190, 1337, 1494, 1660, 1514, 1660, 1817}, + {520, 790, 947, 1117, 1304, 1507, 1724, 1610, 1810, 2024, 2250, 2487, 2737, 3004}, + {997, 1537, 1524, 1804, 2110, 2440, 2794, 3174, 3577, 4004, 4454, 4934, 5434, 5960}, + }; + } + if (craft_list.contains("双面") && craft_list.contains("哑膜")) { + prices = new int[][]{ + {730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730}, + {730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 730}, + {730, 730, 730, 730, 730, 730, 730, 730, 730, 730, 744, 820, 897, 980}, + {730, 730, 730, 730, 730, 800, 914, 1037, 1164, 1297, 1440, 1590, 1750, 1914}, + {730, 730, 747, 880, 1024, 1180, 1347, 1530, 1724, 1924, 2137, 1977, 2174, 2380}, + {730, 1010, 1214, 1437, 1677, 1937, 2220, 2104, 2370, 2654, 2950, 3264, 3594, 3940}, + {1284, 1977, 1994, 2360, 2767, 3197, 3667, 4164, 4697, 5257, 5857, 6480, 7144, 7834}, + }; + } + int[] count_list = new int[]{200, 500, 1000, 2000, 3000, 5000, 10000}; + double[] areas = new double[]{16, 25, 30.25, 36, 42.25, 49, 56.25, 64, 72.25, 81, 90.25, 100, 110.25, 121}; + double area = length * width; + return getAreaCenterPrice(count_list, count, area, prices, areas, number); + } + return new ArrayList<>(); + } + + private List getAreaCenterPrice(int[] count_list, int count, double area, int[][] prices, + double[] areas, int number) { List priceList = new ArrayList<>(); for (int i = 0; i < count_list.length; i++) { int count_item = count_list[i]; diff --git a/src/main/webapp/views/product/pet.jsp b/src/main/webapp/views/product/pet.jsp index 47361af..befd7cb 100644 --- a/src/main/webapp/views/product/pet.jsp +++ b/src/main/webapp/views/product/pet.jsp @@ -209,8 +209,8 @@ }); return false; } - if ((size.split("*")[0] > 10 || size.split("*")[1] > 15) && (size.split("*")[0] > 15 || size.split("*")[1] > 10)) { - layer.msg("【PET透卡】尺寸不能大于10*15 cm", {offset: ['300px', '300px']}, function () { + if ((size.split("*")[0] > 58.7 || size.split("*")[1] > 42.4) && (size.split("*")[0] > 42.4 || size.split("*")[1] > 58.7)) { + layer.msg("【PET透卡】尺寸不能大于58.7*42.4 cm", {offset: ['300px', '300px']}, function () { }); return false; } diff --git a/src/main/webapp/views/product/waterGauge.jsp b/src/main/webapp/views/product/waterGauge.jsp new file mode 100644 index 0000000..e961654 --- /dev/null +++ b/src/main/webapp/views/product/waterGauge.jsp @@ -0,0 +1,330 @@ +<%@ page language="java" contentType="text/html; charset=UTF-8" + pageEncoding="UTF-8" %> +<%@taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> + + + + + Insert title here + <%@include file="/views/common.jsp" %> + + +
+
+

水标

+
+
+ +

+ 材质 +

+
+ +
+

+ 尺寸(CM/厘米) 输入格式: 长 * 宽 +

+
+ +
+ +

+ 数量(个) +

+
+ +
+

+ 款数 +

+
+ +
+

+ 客户旺旺 +

+
+ +
+

+ 工艺 +

+
+
+ 印面: + + +
+
+ 覆膜工艺: + + +
+
+ 裁切工艺: + + +
+
+
+
+ + +
+

计算结果- + +

+
+ + <%@include file="../acountExpressFee.jsp" %> +
+
+
+
+
+
+
+ +
+
+ +<%@include file="/views/copyResult.jsp" %> + + \ No newline at end of file