...
|
...
|
@@ -15,9 +15,7 @@ import com.yohoufo.common.helper.ImageUrlAssist; |
|
|
import com.yohoufo.common.utils.AppVersion;
|
|
|
import com.yohoufo.common.utils.DateUtil;
|
|
|
import com.yohoufo.common.utils.StringUtil;
|
|
|
import com.yohoufo.dal.order.AppraiseOrderMapper;
|
|
|
import com.yohoufo.dal.order.BuyerOrderMapper;
|
|
|
import com.yohoufo.dal.order.DepositCodeMapper;
|
|
|
import com.yohoufo.dal.order.*;
|
|
|
import com.yohoufo.dal.order.model.*;
|
|
|
import org.apache.commons.collections.CollectionUtils;
|
|
|
import org.apache.commons.lang3.StringUtils;
|
...
|
...
|
@@ -50,6 +48,18 @@ public class DepositHelpService { |
|
|
@Autowired
|
|
|
private BuyerOrderMapper buyerOrderMapper;
|
|
|
|
|
|
@Autowired
|
|
|
private SellerOrderGoodsMapper sellerOrderGoodsMapper;
|
|
|
|
|
|
@Autowired
|
|
|
private ServiceOrderProcessor serviceOrderProcessor;
|
|
|
|
|
|
@Autowired
|
|
|
private AppraiseOrderGoodsMapper appraiseOrderGoodsMapper;
|
|
|
|
|
|
@Autowired
|
|
|
private AppraiseOrderStorageMapper appraiseOrderStorageMapper;
|
|
|
|
|
|
// 是否 24小时反馈时间 如果是则返回true
|
|
|
public boolean isFeedback(int depositRemainDay) {
|
|
|
return -1 * DepositOrderComputeResp.FEEDBACK_DAY <= depositRemainDay && depositRemainDay <= 0;
|
...
|
...
|
@@ -273,4 +283,21 @@ public class DepositHelpService { |
|
|
|
|
|
return buyerGoodsMap;
|
|
|
}
|
|
|
|
|
|
public SellerOrderGoods querySellerOrderGoods(StorageDeposit deposit) {
|
|
|
if (serviceOrderProcessor.isGoodsServiceOrder(deposit.getOrderCode())) {
|
|
|
List<AppraiseOrderGoods> appraiseOrderGoodses = appraiseOrderGoodsMapper.selectByOrderCode(deposit.getOrderCode());
|
|
|
|
|
|
AppraiseOrderStorage appraiseOrderStorage = appraiseOrderStorageMapper.selectByOrderCode(deposit.getOrderCode());
|
|
|
|
|
|
SellerOrderGoods sog = new SellerOrderGoods();
|
|
|
sog.setSizeName(null == appraiseOrderStorage ? "" : appraiseOrderStorage.getSizeName());
|
|
|
sog.setProductId(deposit.getProductId());
|
|
|
sog.setProductName(CollectionUtils.isEmpty(appraiseOrderGoodses) ? "" : appraiseOrderGoodses.get(0).getProductName());
|
|
|
return sog;
|
|
|
} else {
|
|
|
return Optional.ofNullable(deposit).map(StorageDeposit::getSkup)
|
|
|
.map(sellerOrderGoodsMapper::selectByPrimaryKey).orElse(null);
|
|
|
}
|
|
|
}
|
|
|
} |
...
|
...
|
|