Commit b80bd9a4 by 徐康

Merge remote-tracking branch 'origin/qa' into qa

parents 7007a876 2f659b46
......@@ -547,7 +547,7 @@ public class OrderCenterSdkServiceImpl implements OrderCenterSdkService {
*/
private OrderTaskReq setAfterSalesOrderTimeOutTask(StoreResponse.Configuration configuration) {
if(configuration != null && 2 == configuration.getTimeTypeOfRefund().intValue()){// 48小时之后
if(configuration != null && (configuration.getTimeTypeOfRefund() != null && 2 == configuration.getTimeTypeOfRefund().intValue()) || configuration.getTimeTypeOfRefund() == null){// 48小时之后
OrderTaskReq orderTask = new OrderTaskReq();
orderTask.setTaskType(4);
orderTask.setTimeout(1);
......@@ -561,7 +561,7 @@ public class OrderCenterSdkServiceImpl implements OrderCenterSdkService {
orderTask.setProcessingTime(DateUtil.convert2String(processingDate, DateUtil.FORMAT_YYYY_MM_DD_HHMMSS));
return orderTask;
}else if(configuration != null && 1 == configuration.getTimeTypeOfRefund().intValue()){// 指定时间
}else if(configuration != null && configuration.getTimeTypeOfRefund() != null && 1 == configuration.getTimeTypeOfRefund().intValue()){// 指定时间
OrderTaskReq orderTask = new OrderTaskReq();
orderTask.setTaskType(4);
orderTask.setTimeout(1);
......
......@@ -383,6 +383,6 @@ public class CartGoods {
/**
* 麦咖啡入机键位
*/
private String keyWord;
private String customerCode;
}
}
......@@ -294,6 +294,8 @@ public class ShoppingCartConvertAdapter {
goods.setSalePrice(materialGoods.getFinalPrice());
goods.setQty(cartGoods.getQty());
goods.setTotalDiscountAmount(0);
goods.setProductCode(materialGoods.getCustomerCode());
goods.setCustomerCode(materialGoods.getCustomerCode());
materialList.add(goods);
}
cartGoodsDetailDto.setMaterialList(materialList);
......@@ -762,7 +764,7 @@ public class ShoppingCartConvertAdapter {
//原行单价*数量
material.setOriginalAmount(detail.getProductFinalPrice().longValue() * cartGoods.getQty());
material.setOriginalPrice(detail.getProductFinalPrice().longValue());
material.setKeyWord(materialGoods.getKeyWord());
material.setCustomerCode(materialGoods.getCustomerCode());
materialGoodsList.add(material);
materialAmount += detail.getProductFinalPrice().longValue() * cartGoods.getQty();
originalMaterAmount += detail.getProductFinalPrice().longValue() * cartGoods.getQty();
......@@ -929,7 +931,6 @@ public class ShoppingCartConvertAdapter {
productMaterial.setOriginalAmount(groupDetailType.getProductPrice().longValue());
productMaterial.setOriginalPrice(groupDetailType.getProductPrice().longValue());
productMaterial.setSpuName(groupDetailType.getProductName());
productMaterial.setKeyWord(productMaterial.getKeyWord());
}
}
}
......
......@@ -302,7 +302,9 @@ public class ShoppingCartGoodsDto {
*/
private Integer totalDiscountAmount;
private String keyWord;
private String productCode;
private String customerCode;
/**
* 当前商品享受的促销活动
*/
......
......@@ -500,6 +500,6 @@ public class CartGoods {
/**
* 麦咖啡入机键位
*/
private String keyWord;
private String customerCode;
}
}
......@@ -24,4 +24,9 @@ public class MaterialRequestVo {
* 加料商品组ID
*/
private String groupId;
/**
* 麦咖啡入机键位
*/
private String customerCode;
}
......@@ -927,27 +927,27 @@ public class ShoppingCartNewServiceImpl implements ShoppingCartNewService {
if (checkSpqInfoResponseDto == null) {
cartGoodsList.remove(i);
assortmentSdkService.setShoppingCart(partnerId, storeId, userId, cartGoodsList, null, null, this.shoppingCartBaseService);
//if (GoodsTypeEnum.HG_COUPON_GOODS.getGoodsType().equals(cartGoods.getGoodsType())) {
// throw new ServiceException(ResponseResult.SHOPPING_CART_HG_COUPON_NOT_EXIST);
//} else {
// throw new ServiceException(ResponseResult.SHOPPING_CART_COUPON_NOT_EXIST);
//}
} else {
validCouponMap.put(spqId, checkSpqInfoResponseDto);
cartGoods.setName(checkSpqInfoResponseDto.getCouponName());
cartGoods.setSpuName(checkSpqInfoResponseDto.getCouponName());
// 添加请求的优惠券信息
ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon coupon = new ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon();
coupon.setCode(checkSpqInfoResponseDto.getCouponCode());
coupon.setActivityCode(checkSpqInfoResponseDto.getActiveCode());
coupons.add(coupon);
// 添加商品券代表的商品
String goodsId = StringUtils.isEmpty(checkSpqInfoResponseDto.getSkuId()) ? checkSpqInfoResponseDto.getSpuId() : checkSpqInfoResponseDto.getSkuId();
if (GoodsTypeEnum.HG_COUPON_GOODS.getGoodsType().equals(cartGoods.getGoodsType())) {
throw new ServiceException(ResponseResult.SHOPPING_CART_HG_COUPON_NOT_EXIST);
this.addCalculationDiscountGoods(calculationDiscountGoodsList, goodsId, 1, checkSpqInfoResponseDto.getPrice(), 100, cartGoodsUid, cartGoods.getSpuId());
} else {
throw new ServiceException(ResponseResult.SHOPPING_CART_COUPON_NOT_EXIST);
this.addCalculationDiscountGoods(calculationDiscountGoodsList, goodsId, 1, checkSpqInfoResponseDto.getPrice(), 100, cartGoodsUid);
}
}
validCouponMap.put(spqId, checkSpqInfoResponseDto);
cartGoods.setName(checkSpqInfoResponseDto.getCouponName());
cartGoods.setSpuName(checkSpqInfoResponseDto.getCouponName());
// 添加请求的优惠券信息
ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon coupon = new ActivityCalculationDiscountRequestDto.CalculationDiscountCoupon();
coupon.setCode(checkSpqInfoResponseDto.getCouponCode());
coupon.setActivityCode(checkSpqInfoResponseDto.getActiveCode());
coupons.add(coupon);
// 添加商品券代表的商品
String goodsId = StringUtils.isEmpty(checkSpqInfoResponseDto.getSkuId()) ? checkSpqInfoResponseDto.getSpuId() : checkSpqInfoResponseDto.getSkuId();
if (GoodsTypeEnum.HG_COUPON_GOODS.getGoodsType().equals(cartGoods.getGoodsType())) {
this.addCalculationDiscountGoods(calculationDiscountGoodsList, goodsId, 1, checkSpqInfoResponseDto.getPrice(), 100, cartGoodsUid, cartGoods.getSpuId());
} else {
this.addCalculationDiscountGoods(calculationDiscountGoodsList, goodsId, 1, checkSpqInfoResponseDto.getPrice(), 100, cartGoodsUid);
}
}
}
......
......@@ -1182,7 +1182,8 @@ public class ShoppingCartMCoffeeServiceImpl {
for (MaterialRequestVo materialRequestVo : vo.getProductMaterialList()) {
CartGoods.MaterialGoods materialGoods = new CartGoods.MaterialGoods();
materialGoods.setSpuId(materialRequestVo.getSpuId());
materialGoods.setGroupId(materialRequestVo.getGroupId());
materialGoods.setCustomerCode(materialRequestVo.getCustomerCode());
// materialGoods.setGroupId(materialRequestVo.getGroupId());
comboxMaterialGoodsList.add(materialGoods);
}
productCombox.setProductMaterialList(comboxMaterialGoodsList);
......
......@@ -367,7 +367,6 @@ public class CouponDiscountCalculation {
res.setStoreId(requestVo.getStoreId());
res.setChannelIdList(commonService.getOrgCodes(requestVo.getPartnerId(), requestVo.getStoreId()));
res.setCouponCodes(couponCodes);
List<CartGoods> productList = new ArrayList<>();
List<CouponProductVo> calculAmountProductList = new ArrayList<>();
if (CollectionUtils.isNotEmpty(cartGoods)) {
cartGoods.forEach(cartGood -> {
......@@ -405,7 +404,7 @@ public class CouponDiscountCalculation {
// });
// }
});
res.setProductList(productList);
res.setProductList(cartGoods);
Long totalAmount = createProductRequest(cartGoods, calculAmountProductList);
res.setTotalAmount(Integer.valueOf(totalAmount.toString()));
resList.add(res);
......
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