Commit 7f62d4df by 刘鹏飞

加些日志

parent 3e977a00
...@@ -96,7 +96,7 @@ public class CocoCouponRelationServiceImpl implements CouponRelationService { ...@@ -96,7 +96,7 @@ public class CocoCouponRelationServiceImpl implements CouponRelationService {
} }
} }
log.info("coco订单核销优惠券,productMap:{}",JSONObject.toJSONString(productMap)); log.info("coco订单核销优惠券,orderCode:{},productMap:{}",orderBean.getOid(),JSONObject.toJSONString(productMap));
// 根据活动号分组,没有活动号的直接筛选掉 // 根据活动号分组,没有活动号的直接筛选掉
Map<String,List<OrderSettlementResp>> orderSettlementMap = orderSettlementList.stream().filter(os -> StringUtils.isNotEmpty(os.getExternalObjectId())) Map<String,List<OrderSettlementResp>> orderSettlementMap = orderSettlementList.stream().filter(os -> StringUtils.isNotEmpty(os.getExternalObjectId()))
...@@ -131,7 +131,7 @@ public class CocoCouponRelationServiceImpl implements CouponRelationService { ...@@ -131,7 +131,7 @@ public class CocoCouponRelationServiceImpl implements CouponRelationService {
List<OrderSettlementResp> orderSettlementRemain = new ArrayList<>(); List<OrderSettlementResp> orderSettlementRemain = new ArrayList<>();
// 已经计算过的促销商品优惠信息 // 已经计算过的促销商品优惠信息
List<OrderSettlementResp> orderSettlementAlready = new ArrayList<>(); List<OrderSettlementResp> orderSettlementAlready = new ArrayList<>();
log.info("coco订单核销优惠券,orderCode:{},orderSettlementMap:{}",orderBean.getOid(),JSONObject.toJSONString(orderSettlementMap));
for (Map.Entry<String,List<OrderSettlementResp>> m : orderSettlementMap.entrySet()) { for (Map.Entry<String,List<OrderSettlementResp>> m : orderSettlementMap.entrySet()) {
// 活动相应的促销明细 // 活动相应的促销明细
...@@ -223,6 +223,7 @@ public class CocoCouponRelationServiceImpl implements CouponRelationService { ...@@ -223,6 +223,7 @@ public class CocoCouponRelationServiceImpl implements CouponRelationService {
// 带有商品的券,计算完之后,要计算整单的优惠券, // 带有商品的券,计算完之后,要计算整单的优惠券,
// 整单的商品减掉单品优惠后的剩下的就都是整单券的商品 // 整单的商品减掉单品优惠后的剩下的就都是整单券的商品
log.info("coco订单核销优惠券,orderCode:{},orderSettlementRemain:{}",orderBean.getOid(),JSONObject.toJSONString(orderSettlementRemain));
if(!orderSettlementRemain.isEmpty()){ if(!orderSettlementRemain.isEmpty()){
Map<String, IntSummaryStatistics> collect = orderSettlementAlready.stream().collect(Collectors.groupingBy(OrderSettlementResp::getProductId, Collectors.summarizingInt(OrderSettlementResp::getNumber))); Map<String, IntSummaryStatistics> collect = orderSettlementAlready.stream().collect(Collectors.groupingBy(OrderSettlementResp::getProductId, Collectors.summarizingInt(OrderSettlementResp::getNumber)));
......
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