Commit 28bdce61 by 孙昱

sunyu::update::fix bug about clear couponInfo for switchCartGoods method

parent ebfb86ad
...@@ -1006,6 +1006,22 @@ public class ShoppingCartMCoffeeServiceImpl { ...@@ -1006,6 +1006,22 @@ public class ShoppingCartMCoffeeServiceImpl {
assortmentSdkService.setShoppingCart(partnerId, toStoreId, userId, cartGoodsList, sessionId, "", shoppingCartBaseService); assortmentSdkService.setShoppingCart(partnerId, toStoreId, userId, cartGoodsList, sessionId, "", shoppingCartBaseService);
//清空商品券商品 //清空商品券商品
clearCartCouponGoods(partnerId, toStoreId, userId, sessionId, cartGoodsList); clearCartCouponGoods(partnerId, toStoreId, userId, sessionId, cartGoodsList);
//当购物车列表里只有一个商品券商品时,clearCartCouponGoods方法不会清空缓存,这里调用clear方法来清空
if (CollectionUtils.isEmpty(cartGoodsList)){
ShoppingCartClearRequestVo clearRequestVo = new ShoppingCartClearRequestVo();
clearRequestVo.setAppId(appId);
clearRequestVo.setUserId(userId);
clearRequestVo.setOperationType(3);
clearRequestVo.setTableNumber(null);
clearRequestVo.setCreateCollageUserId(null);
clearRequestVo.setReceiveId(receiveId);
clearRequestVo.setSessionId(sessionId);
clearRequestVo.setPartnerId(partnerId);
clearRequestVo.setShopId(toStoreId);
clearRequestVo.setOrderType(orderType);
clearRequestVo.setChannelType(menuType);
this.clear(clearRequestVo);
}
// 当couponCode不为空时,需参与价格计算 // 当couponCode不为空时,需参与价格计算
List<ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon> coupons = getCoupon(couponCode, null, cartGoodsList,null,null); List<ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon> coupons = getCoupon(couponCode, null, cartGoodsList,null,null);
...@@ -1023,6 +1039,22 @@ public class ShoppingCartMCoffeeServiceImpl { ...@@ -1023,6 +1039,22 @@ public class ShoppingCartMCoffeeServiceImpl {
assortmentSdkService.setShoppingCart(partnerId, toStoreId, userId, cartGoodsList, sessionId, "", shoppingCartBaseService); assortmentSdkService.setShoppingCart(partnerId, toStoreId, userId, cartGoodsList, sessionId, "", shoppingCartBaseService);
//清空商品券商品 //清空商品券商品
clearCartCouponGoods(partnerId, toStoreId, userId, sessionId, cartGoodsList); clearCartCouponGoods(partnerId, toStoreId, userId, sessionId, cartGoodsList);
//当购物车列表里只有一个商品券商品时,clearCartCouponGoods方法不会清空缓存,这里调用clear方法来清空
if (CollectionUtils.isEmpty(cartGoodsList)){
ShoppingCartClearRequestVo clearRequestVo = new ShoppingCartClearRequestVo();
clearRequestVo.setAppId(appId);
clearRequestVo.setUserId(userId);
clearRequestVo.setOperationType(3);
clearRequestVo.setTableNumber(null);
clearRequestVo.setCreateCollageUserId(null);
clearRequestVo.setReceiveId(receiveId);
clearRequestVo.setSessionId(sessionId);
clearRequestVo.setPartnerId(partnerId);
clearRequestVo.setShopId(toStoreId);
clearRequestVo.setOrderType(orderType);
clearRequestVo.setChannelType(menuType);
this.clear(clearRequestVo);
}
// 当couponCode不为空时,需参与价格计算 // 当couponCode不为空时,需参与价格计算
List<ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon> coupons = getCoupon(couponCode, null, cartGoodsList,null,null); List<ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon> coupons = getCoupon(couponCode, null, cartGoodsList,null,null);
......
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