Commit a1b0dc60 by zhiheng.zhang

Merge branch 'feature/20201124-撤单添加撤单详情-张志恒' into develop

# Conflicts:
#	assortment-ordercenter-sdk/pom.xml
#	assortment-ordercenter-sdk/readme.md
#	order-application-service/pom.xml
#	ordercenter-sdk/pom.xml
#	ordercenter-sdk/readme.md
parents c1276daf 7a7ebdb8
......@@ -98,3 +98,25 @@
| 2.2.0-SNAPSHOT| 混合支付 | 徐康 | 2020-11-16 |
| 2.2.7-SNAPSHOT| 权益卡金额入机 | 徐康 | 2020-11-23 |
| 2.2.8-SNAPSHOT| 添加美团点评渠道 | 梁崇福 | 2020-11-24 |
| 1.5.11.RELEASE | 预约单任务删除RELEASE | wuping | 2020-06-15 |
| 1.5.12.RELEASE | 围餐 | dingkai | 2020-06-16 |
| 1.5.13.RELEASE | 小助手营业额统计 | 梁崇福 | 2020-06-22 |
| 1.5.14.RELEASE | 停车费sdk | dingkai | 2020-06-22 |
| 1.5.16.RELEASE | 增加支付渠道编号 | 李小二 | 2020-07-08 |
| 1.5.17.RELEASE | 停车场订单修改 | 伍平 | 2020-07-13 |
| 2.0.5-RELEASE | 围餐修改 | 谌会阳 | 2020-07-27 |
| 2.0.6-RELEASE | ordercenter新增常量 | 张志恒 | 2020-08-04 |
| 2.0.7-RELEASE | 加料商品开发 | 梁崇福 | 2020-08-24 |
| 2.0.8-RELEASE | 订单渠道映射调整 | 李小二 | 2020-08-24 |
| 2.0.9-RELEASE | 麦咖啡 | 徐康 | 2020-09-07 |
| 2.10.0-RELEASE | 停车场订单 | 张志恒 | 2020-09-28 |
| 2.0.11-RELEASE | 麦咖啡多规格 | 徐康 | 2020-10-09 |
| 2.0.12-RELEASE | 停车场订单 | 张志恒 | 2020-10-14 |
| 2.0.13-RELEASE | 麦咖啡运费券 | 徐康 | 2020-10-20 |
| 2.0.14-RELEASE | 集点推送改造 | 徐康 | 2020-10-28 |
| 2.0.15.RELEASE | 麦咖啡加料 | 徐康 | 2020-10-30 |
| 2.0.16.RELEASE | 麦咖啡问题修复 | 徐康 | 2020-11-09 |
| 2.1.2.RELEASE | 活动扣减库存 | 缪晖 | 2020-11-11 |
| 2.1.3-RELEASE | 退款增加自动退款配置的null判断 | 刘鹏飞 | 2020-11-12 |
| 2.1.4-RELEASE | 退款增加自动退款配置的null判断 | 刘鹏飞 | 2020-11-12 |
| 2.1.5-RELEASE | 麦咖啡权益卡金额入机 | 徐康 | 2020-11-23 |
\ No newline at end of file
......@@ -185,7 +185,7 @@ public class DeliveryAdapter {
if (CollectionUtils.isNotEmpty(order.getProductList())) {
order.getProductList().forEach(productList -> {
ProductInfo deliveryProductInfo = new ProductInfo();
deliveryProductInfo.setProductCode(productList.getProductId());
deliveryProductInfo.setProductCode(productList.getProductId().substring(4));
String productName = StringUtils.isBlank(productList.getSpecificationName()) ? productList.getProductName() : productList.getSpecificationName();
OrderProductAddInfoDto extInfo = JSON.parseObject(productList.getExtInfo(), OrderProductAddInfoDto.class);
if(CollectionUtils.isNotEmpty(extInfo.getSpecialAttrs())) {
......@@ -221,7 +221,7 @@ public class DeliveryAdapter {
if(CollectionUtils.isNotEmpty(productList.getComboProduct())) {
productList.getComboProduct().forEach(comboProduct -> {
ProductInfo deliveryComboProductInfo = new ProductInfo();
deliveryComboProductInfo.setProductCode(comboProduct.getProductId());
deliveryComboProductInfo.setProductCode(comboProduct.getProductId().length()>4?comboProduct.getProductId().substring(4):comboProduct.getProductId());
String productNameCombo = StringUtils.isBlank(comboProduct.getSpecificationName()) ? comboProduct.getProductName() : comboProduct.getSpecificationName();
OrderProductAddInfoDto extInfoCombo = JSON.parseObject(comboProduct.getExtInfo(), OrderProductAddInfoDto.class);
if(CollectionUtils.isNotEmpty(extInfoCombo.getSpecialAttrs())) {
......@@ -251,7 +251,7 @@ public class DeliveryAdapter {
deliveryComboProductInfo.setTaxId(StringUtils.isNotEmpty(orderComboProductAddInfoDto.getTaxId()) ? orderComboProductAddInfoDto.getTaxId() : "10");
deliveryComboProductInfo.setTaxRate(orderComboProductAddInfoDto.getTax() > 0 ? orderComboProductAddInfoDto.getTax() : 6);
deliveryComboProductInfo.setParentCode(Long.valueOf(comboProduct.getParentProductId().replace("_", "")));
deliveryComboProductInfo.setParentCode(Long.valueOf(comboProduct.getParentProductId().replace("_", "").substring(4)));
deliveryProductInfo.setProductCode(deliveryComboProductInfo.getParentCode()+"");
if(CollectionUtils.isNotEmpty(comboProduct.getMaterialProduct())) {
......
......@@ -563,12 +563,21 @@ public class CheckMCCafeOrder {
throw new ServiceException(ResponseResult.SHOPPING_CART_GETINFO_INVAILD);
}
List<MCCafeCouponVo> mcCafeCouponVos = new ArrayList<>();
Map<String, String> mcCafeUsedCoupon = new HashMap<>();
if(CollectionUtils.isNotEmpty(shoppingCartGoodsDto.getActivityDiscountsDtos())) {
shoppingCartGoodsDto.getActivityDiscountsDtos().forEach(o-> {
if(ActivityTypeEnum.TYPE_3.getCode().equals(o.getActivityType()) || ActivityTypeEnum.TYPE_32.getCode().equals(o.getActivityType())
|| ActivityTypeEnum.TYPE_34.getCode().equals(o.getActivityType()) || ActivityTypeEnum.TYPE_35.getCode().equals(o.getActivityType())) {
mcCafeCouponVos.add(new MCCafeCouponVo(o.getActivityCode()));
}
if(ActivityTypeEnum.TYPE_32.getCode().equals(o.getActivityType()) && null != o.getExtendType()
&& (0 == o.getExtendType() || 3 == o.getExtendType() || 4 == o.getExtendType() || 5 == o.getExtendType())) {
if(StringUtils.isNotBlank(mcCafeUsedCoupon.get(o.getActivityCode()))) {
throw new ServiceException(ResponseResult.COUPON_SHOP_NOTSUPPORT, o.getActivityName() + "不可以重复使用");
} else {
mcCafeUsedCoupon.put(o.getActivityCode(), o.getActivityName());
}
}
});
}
if(CollectionUtils.isNotEmpty(mcCafeCouponVos)) {
......
......@@ -184,19 +184,18 @@ public class OrderAdapterServiceImpl implements OrderAdapterService {
// 添加分布式锁,如果没有取得锁直接返回失败;整个方法执行完毕后会删掉该锁
// 锁定秒数从apollo获取,如果apollo没有设置,默认5秒
// String createOrderKey = CREATE_ORDER_KEY + assortmentCustomerInfoVo.getMemberId();
// try {
// Long expire = Long.valueOf(createOrderKeyExpire);
// if(!LockUtils.lock(redisCache.getRedisTemplate(),createOrderKey,expire)){
// return ResponseUtil.error(ResponseResult.ORDER_NOT_CREATE_ERROR);
// }
// return mcCafeOrderService.createMCCafeOrder(createOrderVo);
// } catch (Exception e) {
// throw e;
// } finally {
// //LockUtils.unlock(redisCache.getRedisTemplate(),createOrderKey);
// }
String createOrderKey = CREATE_ORDER_KEY + assortmentCustomerInfoVo.getMemberId();
try {
Long expire = Long.valueOf(createOrderKeyExpire);
if(!LockUtils.lock(redisCache.getRedisTemplate(),createOrderKey,expire)){
return ResponseUtil.error(ResponseResult.ORDER_NOT_CREATE_ERROR);
}
return mcCafeOrderService.createMCCafeOrder(createOrderVo);
} catch (Exception e) {
throw e;
} finally {
//LockUtils.unlock(redisCache.getRedisTemplate(),createOrderKey);
}
}
@Override
......
......@@ -36,4 +36,5 @@
| 1.6.5-SNAPSHOT | 混合支付 | 徐康 | 2020-11-16 |
| 1.6.6-SNAPSHOT | 权益卡金额入机 | 徐康 | 2020-11-23 |
| 1.6.7-SNAPSHOT | 添加美团点评渠道 | 梁崇福 | 2020-11-24 |
| 1.3.20.RELEASE | 麦咖啡权益卡金额入机 | 徐康 | 2020-11-23 |
......@@ -11,4 +11,5 @@ public class ParkingOrderRevokeReq {
private String orderCode;
private String operator;
private String partnerId;
private String cancelReason;
}
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