修改卡片部分工艺价格
This commit is contained in:
@@ -684,8 +684,22 @@ public class ProductService {
|
|||||||
priceList = new CouponPrice().getCouponPrice(min, dto, priceList, count, craftList);
|
priceList = new CouponPrice().getCouponPrice(min, dto, priceList, count, craftList);
|
||||||
craftList.remove("模切");
|
craftList.remove("模切");
|
||||||
dto.setCraft(craftList.toArray(new String[craftList.size()]));
|
dto.setCraft(craftList.toArray(new String[craftList.size()]));
|
||||||
//getCraft(dto, priceList, length * 10, width * 10, min);
|
// getCraft(dto, priceList, length * 10, width * 10, min);
|
||||||
|
for (Product product : priceList) {
|
||||||
|
double carft_price = 0;
|
||||||
|
if (craftList.contains("压痕")) {
|
||||||
|
carft_price += Math.max(0.02 * product.getCount(), 10);
|
||||||
|
}
|
||||||
|
if (craftList.contains("压点线")) {
|
||||||
|
carft_price += Math.max(0.02 * product.getCount(), 10);
|
||||||
|
}
|
||||||
|
if (craftList.contains("圆角")) {
|
||||||
|
carft_price += Math.max(0.02 * product.getCount(), 10);
|
||||||
|
}
|
||||||
|
//腰封的模切费单独计算
|
||||||
|
product.setPrice(Math.ceil((product.getPrice() + carft_price) * number));
|
||||||
|
product.setWeight(df.format(number * length / 100 * width / 100 * product.getCount() * 0.3 * 0.86));
|
||||||
|
}
|
||||||
if (isMq) {
|
if (isMq) {
|
||||||
for (Product product : priceList) {
|
for (Product product : priceList) {
|
||||||
product.setPrice(Math.floor(product.getPrice() * tempNumber));
|
product.setPrice(Math.floor(product.getPrice() * tempNumber));
|
||||||
@@ -4759,13 +4773,13 @@ public class ProductService {
|
|||||||
|
|
||||||
private List<Product> getOtherHekaPrice(Product dto, double length, double width) {
|
private List<Product> getOtherHekaPrice(Product dto, double length, double width) {
|
||||||
int[][] prices = {
|
int[][] prices = {
|
||||||
{79, 79, 79, 79, 79, 79, 79, 79, 79, 91, 92, 92, 95, 96, 135, 139, 152, 186, 340, 345, 435, 450},
|
{79, 79, 79, 79, 79, 79, 79, 79, 79, 91, 92, 92, 95, 125, 135, 139, 152, 186, 340, 345, 435, 450},
|
||||||
{97, 97, 97, 97, 97, 97, 97, 97, 97, 114, 115, 116, 118, 125, 162, 162, 185, 194, 358, 363, 459, 465},
|
{97, 97, 97, 97, 97, 97, 97, 97, 97, 114, 115, 116, 118, 158, 162, 162, 185, 194, 358, 363, 459, 465},
|
||||||
{153, 153, 153, 153, 153, 153, 153, 153, 153, 169, 171, 172, 175, 180, 251, 256, 286, 291, 480, 490, 620, 635},
|
{153, 153, 153, 153, 153, 153, 153, 153, 153, 169, 171, 172, 175, 234, 251, 256, 286, 291, 480, 490, 620, 635},
|
||||||
{250, 250, 250, 250, 250, 250, 250, 250, 250, 266, 273, 275, 278, 280, 360, 370, 429, 442, 640, 655, 825, 877},
|
{250, 250, 250, 250, 250, 250, 250, 250, 250, 266, 273, 275, 278, 330, 360, 370, 429, 442, 640, 655, 825, 877},
|
||||||
{370, 370, 370, 370, 370, 370, 370, 370, 370, 371, 372, 373, 375, 378, 500, 515, 545, 632, 800, 886, 1030, 1240},
|
{370, 370, 370, 370, 370, 370, 370, 370, 370, 371, 372, 373, 375, 480, 500, 515, 545, 632, 800, 886, 1030, 1240},
|
||||||
{510, 510, 510, 510, 510, 510, 510, 510, 510, 589, 600, 605, 610, 615, 800, 820, 932, 1022, 1160, 1458, 1488, 2000},
|
{510, 510, 510, 510, 510, 510, 510, 510, 510, 589, 600, 605, 610, 750, 800, 820, 932, 1022, 1160, 1458, 1488, 2000},
|
||||||
{945, 945, 945, 945, 945, 945, 945, 945, 945, 1030, 1040, 1045, 1050, 1055, 1440, 1460, 1798, 2202, 2400, 2950, 3012, 4000},
|
{945, 945, 945, 945, 945, 945, 945, 945, 945, 1030, 1040, 1045, 1050, 1200, 1440, 1460, 1798, 2202, 2400, 2950, 3012, 4000},
|
||||||
};
|
};
|
||||||
int[] count_list = {200, 500, 1000, 2000, 3000, 5000, 10000};
|
int[] count_list = {200, 500, 1000, 2000, 3000, 5000, 10000};
|
||||||
double[] areas = {4, 16, 25, 30, 35, 36, 40, 45, 48.60, 49, 54, 64, 81, 97.20, 100, 145.80, 172.8, 194.4, 224, 288, 294, 400};
|
double[] areas = {4, 16, 25, 30, 35, 36, 40, 45, 48.60, 49, 54, 64, 81, 97.20, 100, 145.80, 172.8, 194.4, 224, 288, 294, 400};
|
||||||
|
|||||||
@@ -33,7 +33,7 @@
|
|||||||
<if test="updateDate != null">
|
<if test="updateDate != null">
|
||||||
updateDate = now(),
|
updateDate = now(),
|
||||||
</if>
|
</if>
|
||||||
<if test="attachment != null">
|
<if test="title != null">
|
||||||
title = #{title,jdbcType=VARCHAR},
|
title = #{title,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
</set>
|
</set>
|
||||||
|
|||||||
Reference in New Issue
Block a user