新增卡片工艺

This commit is contained in:
2026-07-31 16:35:45 +08:00
parent e097316fba
commit 454c0ec1d7
2 changed files with 58 additions and 12 deletions
@@ -898,12 +898,19 @@ public class ProductService {
if (craft_list.contains("穿尼龙绳")) { if (craft_list.contains("穿尼龙绳")) {
carft_price += Math.max(0.2 * item_count, 40); carft_price += Math.max(0.2 * item_count, 40);
} }
if (craft_list.contains("配红白格丝带")) {
carft_price += Math.max(0.25 * item_count, 10);
}
if (craft_list.contains("穿红白格丝带")) {
carft_price += Math.max(0.3 * item_count, 10);
}
if (craft_list.contains("配弹力绳")) { if (craft_list.contains("配弹力绳")) {
carft_price += Math.max(0.1 * item_count, 10); carft_price += Math.max(0.1 * item_count, 10);
} }
if (craft_list.contains("配弹力绳捆")) { if (craft_list.contains("配弹力绳捆")) {
carft_price += 10 * Math.ceil(item_count * 20.0 / 5000); carft_price += 10 * Math.ceil(item_count * 20.0 / 5000);
} }
double tang_price = 0; double tang_price = 0;
if (craft_list.contains("单面烫金") || craft_list.contains("双面烫金")) { if (craft_list.contains("单面烫金") || craft_list.contains("双面烫金")) {
tang_price = new PriceUtils().TablePrice(area, tang_prices[count_index], tang_areas); tang_price = new PriceUtils().TablePrice(area, tang_prices[count_index], tang_areas);
@@ -1090,6 +1097,12 @@ public class ProductService {
if (craft_list.contains("穿尼龙绳")) { if (craft_list.contains("穿尼龙绳")) {
carft_price += Math.max(0.2 * product.getCount(), 40); carft_price += Math.max(0.2 * product.getCount(), 40);
} }
if (craft_list.contains("配红白格丝带")) {
carft_price += Math.max(0.25 * product.getCount(), 10);
}
if (craft_list.contains("穿红白格丝带")) {
carft_price += Math.max(0.3 * product.getCount(), 10);
}
if (craft_list.contains("配弹力绳")) { if (craft_list.contains("配弹力绳")) {
carft_price += Math.max(0.1 * product.getCount(), 10); carft_price += Math.max(0.1 * product.getCount(), 10);
} }
@@ -9648,20 +9661,27 @@ public class ProductService {
} }
} }
if ("特种纸名片".equals(dto.getProTypeValue()) && craftList.contains("异形模切")) {// 200-500张按照原有的价格乘以3倍 1000-5000张按照原有的价格乘以2.4倍 5000-10000张按照原有的价格乘以2倍 if ("特种纸名片".equals(dto.getProTypeValue()) && craftList.contains("异形模切")) {// 200-500张按照原有的价格乘以3倍 1000-5000张按照原有的价格乘以2.4倍 5000-10000张按照原有的价格乘以2倍
double[] prices = {112, 152, 208, 376, 552, 888, 1328}; double[] prices = {1560, 1720, 2320, 5840, 8520, 9680, 12900};
int[] counts = {200, 500, 1000, 2000, 3000, 5000, 10000}; int[] counts = {200, 500, 1000, 2000, 3000, 5000, 10000};
int num = getNum(width, length); int num = getNum(width, length);
if (num == 1) { double[][] prices_area = {
} else if (num == 2) { {112, 152, 208, 376, 552, 888, 1328},
prices = new double[]{200, 280, 380, 688, 1000, 1620, 2420}; {200, 280, 380, 688, 1000, 1620, 2420},
} else if (num == 3) { {272, 376, 500, 912, 1320, 2140, 3100},
prices = new double[]{272, 376, 500, 912, 1320, 2140, 3100}; {328, 448, 600, 1088, 1576, 2440, 3600},
} else if (num == 5 || num == 4) { {380, 520, 696, 1260, 1832, 2740, 4100},
prices = new double[]{380, 520, 696, 1260, 1832, 2740, 4100}; {480, 640, 880, 1520, 2040, 3200, 4800},
} else if (num == 6) { {600, 760, 1040, 2000, 2760, 3920, 5700},
prices = new double[]{480, 640, 880, 1520, 2040, 3200, 4800}; {720, 880, 1200, 2480, 3480, 4640, 6600},
} else { {840, 1000, 1360, 2960, 4200, 5360, 7500},
prices = new double[]{600, 760, 1040, 2000, 2760, 3920, 5700}; {960, 1120, 1520, 3440, 4920, 6080, 8400},
{1080, 1240, 1680, 3920, 5640, 6800, 9300},
{1200, 1360, 1840, 4400, 6360, 7520, 10200},
{1320, 1480, 2000, 4880, 7080, 8240, 11100},
{1440, 1600, 2160, 5360, 7800, 8960, 12000},
};
if (num < 15) {
prices = prices_area[num - 1];
} }
for (Product product : priceList) { for (Product product : priceList) {
for (int i = 0; i < counts.length; i++) { for (int i = 0; i < counts.length; i++) {
@@ -9703,6 +9723,7 @@ public class ProductService {
} }
} }
} }
} }
public List<Product> chucklePrice(String role, List<Product> list, Product dto) { public List<Product> chucklePrice(String role, List<Product> list, Product dto) {
+25
View File
@@ -1007,6 +1007,14 @@
style="width: 70px"/> style="width: 70px"/>
</div> </div>
</div> </div>
<input type="checkbox" class="peijian" name="craft" lay-filter="z4PeiJian" value="红白格丝带"
title="红白格丝带">
<div class="layui-inline select_sidai" style="width: 110px;display: none">
<select class="select" name="craft" disabled>
<option value="配红白格丝带">配红白格丝带</option>
<option value="穿红白格丝带">穿红白格丝带</option>
</select>
</div>
</div> </div>
</form> </form>
</div> </div>
@@ -1405,6 +1413,8 @@
$("#peijian_ui .gscolor select").prop("disabled", true); $("#peijian_ui .gscolor select").prop("disabled", true);
$("#peijian_ui .select_nilongshen").hide(); $("#peijian_ui .select_nilongshen").hide();
$("#peijian_ui .select_nilongshen select").prop("disabled", true); $("#peijian_ui .select_nilongshen select").prop("disabled", true);
$("#peijian_ui .select_sidai").hide();
$("#peijian_ui .select_sidai select").prop("disabled", true);
$("#peijian_ui .select_liusu").hide(); $("#peijian_ui .select_liusu").hide();
$("#peijian_ui .select_liusu select").prop("disabled", true); $("#peijian_ui .select_liusu select").prop("disabled", true);
$("#peijian_ui .opp").hide(); $("#peijian_ui .opp").hide();
@@ -1527,6 +1537,17 @@
$("#peijian_ui .select_nilongshen select").prop("disabled", true); $("#peijian_ui .select_nilongshen select").prop("disabled", true);
} }
} }
if (data.value == "红白格丝带") {
if ($(data.elem).is(":checked")) {
$("#peijian_ui .select_sidai").show();
$("#peijian_ui .select_sidai select").prop("disabled", false);
getProductImage('红白格丝带');
} else {
$("#peijian_ui .select_sidai").hide();
$("#peijian_ui .select_sidai select").prop("disabled", true);
getProductImage('');
}
}
if (data.value == "配弹力绳" || data.value == "配弹力绳捆") { if (data.value == "配弹力绳" || data.value == "配弹力绳捆") {
if ($(data.elem).is(":checked")) { if ($(data.elem).is(":checked")) {
$("#peijian_ui .tscolor").show(); $("#peijian_ui .tscolor").show();
@@ -3626,6 +3647,10 @@
arr.push($(".select_nilongshen select[name='craft'] option:selected").val() + "-" + $("select[name='shen_color'] option:selected").val()) arr.push($(".select_nilongshen select[name='craft'] option:selected").val() + "-" + $("select[name='shen_color'] option:selected").val())
return; return;
} }
if ($(this).val() === '红白格丝带') {
arr.push($(".select_sidai select[name='craft'] option:selected").val())
return;
}
if ($(this).val() === '配尼龙绳' || $(this).val() === '穿尼龙绳') { if ($(this).val() === '配尼龙绳' || $(this).val() === '穿尼龙绳') {
let shenColor = $("select[name='shen_color'] option:selected").val(); let shenColor = $("select[name='shen_color'] option:selected").val();
if (couponKind == "少数量") { if (couponKind == "少数量") {