修改特种纸名片模切价格

This commit is contained in:
2025-10-21 17:27:11 +08:00
vanhempi f3eaf66d56
commit d77e26f423
2 muutettua tiedostoa jossa 5 lisäystä ja 5 poistoa
@@ -6353,16 +6353,16 @@ public class ProductService {
if ("特种纸名片".equals(dto.getProTypeValue()) && craftList.contains("异形模切") && !craftList.contains("单面烫金") && !craftList.contains("双面烫金")) {// 200-500张按照原有的价格乘以3倍 1000-5000张按照原有的价格乘以2.4倍 5000-10000张按照原有的价格乘以2倍 if ("特种纸名片".equals(dto.getProTypeValue()) && craftList.contains("异形模切") && !craftList.contains("单面烫金") && !craftList.contains("双面烫金")) {// 200-500张按照原有的价格乘以3倍 1000-5000张按照原有的价格乘以2.4倍 5000-10000张按照原有的价格乘以2倍
for (Product product : priceList) { for (Product product : priceList) {
if (200 <= product.getCount() && product.getCount() <= 500) { if (200 <= product.getCount() && product.getCount() <= 500) {
product.setPrice(Math.ceil(product.getPrice() * 1.9)); product.setPrice(Math.ceil(product.getPrice() * 3));
} }
if (500 < product.getCount() && product.getCount() <= 1000) { if (500 < product.getCount() && product.getCount() <= 1000) {
product.setPrice(Math.ceil(product.getPrice() * 2.3)); product.setPrice(Math.ceil(product.getPrice() * 2.6));
} }
if (1000 < product.getCount() && product.getCount() <= 5000) { if (1000 < product.getCount() && product.getCount() <= 5000) {
product.setPrice(Math.ceil(product.getPrice() * 2.4)); product.setPrice(Math.ceil(product.getPrice() * 2.4));
} }
if (5000 < product.getCount() && product.getCount() <= 10000) { if (5000 < product.getCount() && product.getCount() <= 10000) {
product.setPrice(Math.ceil(product.getPrice() * 2.5)); product.setPrice(Math.ceil(product.getPrice() * 2));
} }
} }
} }
@@ -99,7 +99,7 @@
<div class="layui-form-item"> <div class="layui-form-item">
<div class="layui-input-block" style="display:inline-block;"> <div class="layui-input-block" style="display:inline-block;">
配件: 配件:
<input type="checkbox" name="craft" lay-filter="ui_craft" value="切割机" title="切割机"> <input type="checkbox" name="craft" lay-filter="ui_craft" value="切割机" title="底座切割机">
<div class="layui-inline qiege" style="width:100px; display:none"> <div class="layui-inline qiege" style="width:100px; display:none">
<label style="display: flex;align-items: center"> <label style="display: flex;align-items: center">
<span style="flex-shrink: 0">数量:</span> <span style="flex-shrink: 0">数量:</span>
@@ -329,7 +329,7 @@
$("input[name='craft']:checked").each(function () { $("input[name='craft']:checked").each(function () {
if (!$(this).is(':disabled')) { if (!$(this).is(':disabled')) {
if ($(this).val() == "切割机") { if ($(this).val() == "切割机") {
craft.push($(this).val() + $("input[name='stickNum']").val() + "个"); craft.push($(this).attr("title") + $("input[name='stickNum']").val() + "个");
} }
} }
} }