...
|
...
|
@@ -2,16 +2,14 @@ package com.yohoufo.order.service.impl; |
|
|
|
|
|
import com.yohobuy.ufo.model.order.bo.ButtonShowBo;
|
|
|
import com.yohobuy.ufo.model.order.bo.OrderInfo;
|
|
|
import com.yohobuy.ufo.model.order.common.OrderCodeType;
|
|
|
import com.yohobuy.ufo.model.order.common.OrderStatus;
|
|
|
import com.yohobuy.ufo.model.order.common.SkupStatus;
|
|
|
import com.yohobuy.ufo.model.order.common.TabType;
|
|
|
import com.yohobuy.ufo.model.order.common.*;
|
|
|
import com.yohoufo.common.utils.DateUtil;
|
|
|
import com.yohoufo.dal.order.model.BuyerOrder;
|
|
|
import com.yohoufo.order.common.Payment;
|
|
|
import com.yohoufo.order.model.dto.BuyerPenaltyCalResult;
|
|
|
import com.yohoufo.order.model.response.OrderDetailInfo;
|
|
|
import com.yohoufo.order.service.handler.BuyerCancelCompensateComputeHandler;
|
|
|
import com.yohoufo.order.utils.BuyerOrderUtils;
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.slf4j.Logger;
|
|
|
import org.slf4j.helpers.MessageFormatter;
|
...
|
...
|
@@ -39,6 +37,9 @@ public abstract class AbsOrderViewService { |
|
|
if (CollectionUtils.isEmpty(buttons)){
|
|
|
return buttons;
|
|
|
}
|
|
|
|
|
|
disableBuyAgainIfOffline(buyerOrder, buttons);
|
|
|
|
|
|
//TODO optimized first query out status of order need BuyerPenaltyCalResult
|
|
|
int orderStatusCode = buyerOrder.getStatus();
|
|
|
|
...
|
...
|
@@ -68,6 +69,21 @@ public abstract class AbsOrderViewService { |
|
|
return buttonsClone;
|
|
|
}
|
|
|
|
|
|
/**
|
|
|
* 门店订单,不需要“再次购买”,替换为“查看详情”
|
|
|
* @param buyerOrder
|
|
|
* @param buttons
|
|
|
*/
|
|
|
private void disableBuyAgainIfOffline(final BuyerOrder buyerOrder, final List<ButtonShowBo> buttons) {
|
|
|
if(BuyerOrderUtils.isOffline(buyerOrder.getAttributes())
|
|
|
&& buttons != null && buttons.contains(ButtonShow.BUY_AGAIN.getBo())) {
|
|
|
buttons.remove(ButtonShow.BUY_AGAIN.getBo());
|
|
|
if(!buttons.contains(ButtonShow.SHOW_DETAIL.getBo())) {
|
|
|
buttons.add(ButtonShow.SHOW_DETAIL.getBo());
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
|
|
|
String formatconfirmTips(BuyerPenaltyCalResult bpcr,int orderStatusCode, String temp){
|
|
|
Object[] formatParms = new Object[1];
|
|
|
String confirmTips = temp;
|
...
|
...
|
|