Commit 51c8dd4b by 孙昱

sunyu::update::fix bug about monthCard 2.0

parent ffdbaa5f
...@@ -1407,7 +1407,7 @@ public class ShoppingCartMCoffeeServiceImpl { ...@@ -1407,7 +1407,7 @@ public class ShoppingCartMCoffeeServiceImpl {
List<CartGoods> montCardGoods = oldCartGoodsList.stream().filter(c-> c.getIsMonthCardGoods()>0).collect(Collectors.toList()); List<CartGoods> montCardGoods = oldCartGoodsList.stream().filter(c-> c.getIsMonthCardGoods()>0).collect(Collectors.toList());
if (CollectionUtils.isNotEmpty(montCardGoods)){ if (CollectionUtils.isNotEmpty(montCardGoods)){
for (CartGoods montCardGood : montCardGoods) { for (CartGoods montCardGood : montCardGoods) {
if (newCartGoods.get(0).getGoodsId().equals(montCardGood.getGoodsId())){ if (StringUtils.isEmpty(newCartGoods.get(0).getCouponCode()) && newCartGoods.get(0).getGoodsId().equals(montCardGood.getGoodsId())){
newCartGoods.get(0).setCouponCode(montCardGood.getCouponCode()); newCartGoods.get(0).setCouponCode(montCardGood.getCouponCode());
} }
} }
......
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