Authored by mali

Merge branch 'hotfix_0724' into test6.9.9

Conflicts:
	order/src/main/java/com/yohoufo/order/service/deposit/DepositOrderService.java
... ... @@ -14,4 +14,12 @@ public interface IBuyerOrderMetaService {
AddressInfo getHiddenAddressInfo(int uid, long orderCode);
CustomsClearanceResult getCustomsClearanceResult(int uid, long orderCode);
/**
* 获取召回地址
* @param uid
* @param orderCode
* @return
*/
AddressInfo getRecallAddressInfo(int uid, long orderCode);
}
... ...
... ... @@ -191,7 +191,7 @@ public class DepositOrderService {
ExpressInfoDetail lastExpressInfoDetail = queryExpressInfoDetail(depositDetailBo); // 查询最新的物流动态
AddressInfo addressInfo = buyerOrderMetaService.getHiddenAddressInfo(req.getUid(), storageDeposit.getOrderCode());
AddressInfo addressInfo = buyerOrderMetaService.getRecallAddressInfo(req.getUid(), storageDeposit.getOrderCode());
GoodsInfo goodsInfo = getGoodsInfo(storageDeposit.getSkup()); // 查询购买商品的详细信息
... ...
... ... @@ -140,4 +140,24 @@ public class BuyerOrderMetaServiceImpl implements IBuyerOrderMetaService {
return ccr;
}
/**
* 优先取召回地址,如果没有取到就取默认发货地址
* @param uid
* @param orderCode
* @return
*/
@Override
public AddressInfo getRecallAddressInfo(int uid, long orderCode){
BuyerOrderMeta recallAddress = getBuyerOrderMeta(uid, orderCode, MetaKey.RECALL_HIDDEN_ADDRESS);
AddressInfo userAddress = null;
if (null == recallAddress) {
recallAddress = getBuyerOrderMeta(uid, orderCode, MetaKey.BUYER_DELIVERY_HIDDEN_ADDRESS);
}
if ( null != recallAddress && StringUtils.isNotBlank(recallAddress.getMetaValue())){
userAddress = JSONObject.parseObject(recallAddress.getMetaValue(), AddressInfo.class);
}
return userAddress;
}
}
... ...