Commit 4134840d by xiaoer.li@freemud.com

fix

parent be20d9db
...@@ -52,7 +52,8 @@ public enum ActivityTypeEnum { ...@@ -52,7 +52,8 @@ public enum ActivityTypeEnum {
TYPE_200(200, "X元Y件"), TYPE_200(200, "X元Y件"),
TYPE_PACKAGE(900, "包装费"), TYPE_PACKAGE(900, "包装费"),
TYPE_DELIVERY(901, "配送费"), TYPE_DELIVERY(901, "配送费"),
TYPE_320(320,"会员价商品优惠"); TYPE_320(320, "会员价商品优惠"),
TYPE_221(221, "集点");
private Integer code; private Integer code;
......
...@@ -85,15 +85,18 @@ public class CustomerScoreService implements IPromotionService { ...@@ -85,15 +85,18 @@ public class CustomerScoreService implements IPromotionService {
} }
} }
//集点 //集点
long discountCount = calculationDiscountResult.getDiscounts().stream().filter(discount -> !ActivityTypeEnum.TYPE_221.getCode().equals(discount.getType())).count();
/*
int discountCount = calculationDiscountResult.getDiscounts().size(); int discountCount = calculationDiscountResult.getDiscounts().size();
int type211 = 0; int type211 = 0;
for (ActivityCalculationDiscountResponseDto.CalculationDiscountResult.Discount discount : calculationDiscountResult.getDiscounts()) { for (ActivityCalculationDiscountResponseDto.CalculationDiscountResult.Discount discount : calculationDiscountResult.getDiscounts()) {
if (discount.getType().equals(221)) { if (ActivityTypeEnum.TYPE_221.getCode().equals(discount.getType())) {
type211 += 1; type211 += 1;
break; break;
} }
} }
discountCount = discountCount - type211; discountCount = discountCount - type211;
*/
//积分抵扣开关禁用 有换购活动 且选中了换购商品 //积分抵扣开关禁用 有换购活动 且选中了换购商品
// - 有换购且选中了换购商品 // - 有换购且选中了换购商品
// - 有换购且没有选中换购商品 且除集点以外还有其他促销 // - 有换购且没有选中换购商品 且除集点以外还有其他促销
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment