Commit 34646721 by 刘鹏飞

Merge remote-tracking branch 'remotes/origin/feature/coco-payGift-刘鹏飞' into develop

parents d8afc5bc 6dc4876b
......@@ -270,7 +270,7 @@ public class OrderSdkAdapter {
}
// 买一赠一寄件信息
if(requestVO.getChooseGoods() != null || !requestVO.getChooseGoods().isEmpty()){
if(requestVO.getChooseGoods() != null && !requestVO.getChooseGoods().isEmpty()){
request.setChooseGoods(JSONArray.parseArray(JSONObject.toJSONString(requestVO.getChooseGoods()), CreateOrderRequest.ChooseGood.class));
}
......
......@@ -318,7 +318,7 @@ public class OrderAdapter {
createOrderDto.setPayChannelType(createOrderVo.getPayChannelType());
// 买一赠一寄件信息
if(createOrderVo.getChooseGoods() != null || !createOrderVo.getChooseGoods().isEmpty()){
if(createOrderVo.getChooseGoods() != null && !createOrderVo.getChooseGoods().isEmpty()){
createOrderDto.setChooseGoods(JSONArray.parseArray(JSONObject.toJSONString(createOrderVo.getChooseGoods()), BaseCreateOrderRequest.ChooseGood.class));
}
return createOrderDto;
......
......@@ -59,6 +59,8 @@ public class ShoppingCartInfoRequestVo extends BaseRequestVo {
* 优惠券code
*/
private String couponCode;
private List<String> couponCodes;
/**
* 优惠券对应的活动号
*/
......
......@@ -578,6 +578,16 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
coupon.setActivityCode(activityCode);
coupons.add(coupon);
}
if (shoppingCartInfoRequestVo.getCouponCodes() != null) {
shoppingCartInfoRequestVo.getCouponCodes().forEach(s->{
CalculationSharingDiscountRequestDto.CalculationDiscountCoupon coupon = new CalculationSharingDiscountRequestDto.CalculationDiscountCoupon();
coupon.setCode(s);
coupons.add(coupon);
});
}
List<ShoppingCartInfoRequestVo.SendGoods> sendGoodsList = shoppingCartInfoRequestVo.getSendGoods();
List<ShoppingCartInfoRequestVo.SendGoods> sendGoods = new ArrayList<>();
if (CollectionUtils.isNotEmpty(sendGoodsList)) {
......
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