Authored by Lixiaodi

Merge branch 'test6.9.8' of http://git.yoho.cn/ufo/yohoufo-fore into test6.9.8

... ... @@ -74,6 +74,7 @@ public class ShoppingController {
@RequestMapping(params = "method=ufo.order.selectCoupon")
public ApiResponse selectCoupon(@RequestParam(name = "uid") int uid,
@RequestParam(name = "skup") int skup,
@RequestParam(name = "addressId", required = false) String addressId,
@RequestParam(name = "coupon_code",required = false) String couponCode,
@RequestParam(name="depositRequirement", required = false, defaultValue = OrderConstant.N_STR)String depositRequirement) {
//活动类型
... ... @@ -84,6 +85,7 @@ public class ShoppingController {
.couponCodes(activityTypeEnum.isCouponFlag() ? CouponCodeUtils.asList(couponCode) : null)
.userActivityId(0).activityType(activityTypeEnum)
.depositRequirement(depositRequirement)
.addressId(addressId)
.build();
logger.info("in ufo.order.selectCoupon, req {}", req);
ShoppingCouponListResp resp = buyerOrderService.selectCoupon(req);
... ...
... ... @@ -342,7 +342,10 @@ public class ShoppingServiceImpl implements IShoppingService {
//构建算费
ChargeContext chargeContext = buildChargeContext(request, skupGood, activityPrice, ChargeParam.SELECT_COUPON);
if (StringUtils.isNoneBlank(request.getAddressId())){
Pair<AddressInfo, AddressInfo> addressInfoPair = getAndCheckAddressInfo(request);
chargeContext.setUserAddressPair(addressInfoPair);
}
//算费
chargeService.charge(chargeContext);
... ...