|
@ -242,6 +242,19 @@ namespace BBWY.Server.Business |
|
|
else if (purchasePlatform == Enums.Platform.阿里巴巴) |
|
|
else if (purchasePlatform == Enums.Platform.阿里巴巴) |
|
|
tradeMode = extJson.Value<string>("OrderTradeTypeCode"); |
|
|
tradeMode = extJson.Value<string>("OrderTradeTypeCode"); |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
#region 处理JD SKU和拳探SKU的对应关系
|
|
|
|
|
|
var belongSkus_mappingList = new List<JObject>(); |
|
|
|
|
|
foreach (var belongSkuGroup in belongSkuGroups) |
|
|
|
|
|
{ |
|
|
|
|
|
var firstProductParam = belongSkuGroup.FirstOrDefault(); |
|
|
|
|
|
if (!belongSkus_mappingList.Any(j => j.Value<string>("BelongSkuId") == firstProductParam.BelongSkuId)) |
|
|
|
|
|
{ |
|
|
|
|
|
belongSkus_mappingList.Add(JObject.FromObject(new { firstProductParam.BelongSkuId, SkuId = firstProductParam.PurchaseSkuId })); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
#endregion
|
|
|
|
|
|
|
|
|
var createOrderResponse = platformSDKBusinessList.FirstOrDefault(p => p.Platform == purchasePlatform) |
|
|
var createOrderResponse = platformSDKBusinessList.FirstOrDefault(p => p.Platform == purchasePlatform) |
|
|
.FastCreateOrder(new CreateOnlinePurchaseOrderRequest() |
|
|
.FastCreateOrder(new CreateOnlinePurchaseOrderRequest() |
|
|
{ |
|
|
{ |
|
@ -253,7 +266,7 @@ namespace BBWY.Server.Business |
|
|
PurchaseOrderMode = request.PurchaseOrderMode, |
|
|
PurchaseOrderMode = request.PurchaseOrderMode, |
|
|
Remark = request.Remark, |
|
|
Remark = request.Remark, |
|
|
SourceShopName = request.ShopName, |
|
|
SourceShopName = request.ShopName, |
|
|
SourceSku = string.Join(",", belongSkuGroups.Select(g => g.Key)), |
|
|
SourceSku = belongSkus_mappingList, |
|
|
CargoParamList = productParamList.Select(p => new CargoParamRequest() |
|
|
CargoParamList = productParamList.Select(p => new CargoParamRequest() |
|
|
{ |
|
|
{ |
|
|
ProductId = p.PurchaseProductId, |
|
|
ProductId = p.PurchaseProductId, |
|
|