...
|
...
|
@@ -4,6 +4,7 @@ import com.google.common.collect.Lists; |
|
|
import com.yohobuy.ufo.model.order.bo.PrdPrice;
|
|
|
import com.yohobuy.ufo.model.order.bo.SellerBo;
|
|
|
import com.yohobuy.ufo.model.order.common.OrderStatus;
|
|
|
import com.yohobuy.ufo.model.order.common.Payment;
|
|
|
import com.yohobuy.ufo.model.order.common.SellerFuncEnum;
|
|
|
import com.yohobuy.ufo.model.order.common.SkupStatus;
|
|
|
import com.yohobuy.ufo.model.order.constants.SkupType;
|
...
|
...
|
@@ -18,19 +19,18 @@ import com.yohoufo.dal.order.model.BuyerOrder; |
|
|
import com.yohoufo.dal.order.model.BuyerOrderGoods;
|
|
|
import com.yohoufo.dal.order.model.SellerOrder;
|
|
|
import com.yohoufo.dal.order.model.SellerOrderGoods;
|
|
|
import com.yohobuy.ufo.model.order.common.Payment;
|
|
|
import com.yohoufo.order.model.dto.ChangePricePrepareDTO;
|
|
|
import com.yohoufo.order.model.dto.SellerOrderComputeResult;
|
|
|
import com.yohoufo.order.model.dto.SkupDto;
|
|
|
import com.yohoufo.order.model.request.PrdQueryReq;
|
|
|
import com.yohoufo.order.service.seller.setting.SellerService;
|
|
|
import com.yohoufo.order.service.seller.OrderComputeHandler;
|
|
|
import com.yohoufo.order.service.seller.OrderComputeProvider;
|
|
|
import com.yohoufo.order.service.seller.SellerAuthCheckService;
|
|
|
import com.yohoufo.order.service.seller.fee.GoodsAmountService;
|
|
|
import com.yohoufo.order.service.seller.processor.ChangePriceCommonPrepareProcessor;
|
|
|
import com.yohoufo.order.service.seller.processor.PriceComputePrepareProcessor;
|
|
|
import com.yohoufo.order.service.seller.setting.SellerService;
|
|
|
import com.yohoufo.order.utils.LoggerUtils;
|
|
|
import com.yohoufo.order.utils.OrderAssist;
|
|
|
import com.yohoufo.order.utils.SellerGoodsHelper;
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.slf4j.Logger;
|
...
|
...
|
@@ -74,6 +74,9 @@ public class SingleGoodsChangePricePrepareProcessor { |
|
|
@Autowired
|
|
|
private ChangePriceCommonPrepareProcessor changePriceCommonPrepareProcessor;
|
|
|
|
|
|
@Autowired
|
|
|
private GoodsAmountService goodsAmountService;
|
|
|
|
|
|
public void checkGoodsStatus(SellerOrderGoods psog){
|
|
|
if (SkupStatus.CAN_SELL.getCode() != psog.getStatus().intValue()){
|
|
|
logger.warn("in SingleGoodsChangePricePrepareProcessor.checkGoodsStatus not can sale, SellerOrderGoods {}", psog);
|
...
|
...
|
@@ -131,8 +134,7 @@ public class SingleGoodsChangePricePrepareProcessor { |
|
|
|
|
|
String tips = priceComputePrepareProcessor.checkSuggestPrice(prdPrice, salePrice, skupType);
|
|
|
// compute every fee from price
|
|
|
boolean isImperfect = SellerGoodsHelper.isImperfectGoods(skupType);
|
|
|
SellerOrderComputeResult pcc = isImperfect ? null : OrderAssist.buildPersonalComputeConfig(prdPrice);
|
|
|
SellerOrderComputeResult pcc = goodsAmountService.getGoodsServiceFeeRate(uid, storageId, prdPrice, skupType);
|
|
|
OrderComputeHandler computeHandler = orderComputeProvider.findBySkupType(skupType);
|
|
|
SellerOrderComputeResult computeResult = computeHandler.compute(salePrice, pcc);
|
|
|
//check income
|
...
|
...
|
|