|
@ -2396,16 +2396,16 @@ namespace BBWYB.Server.Business |
|
|
{ |
|
|
{ |
|
|
case "ORDER_BUYER_VIEW_PART_PART_SENDGOODS": //部分发货
|
|
|
case "ORDER_BUYER_VIEW_PART_PART_SENDGOODS": //部分发货
|
|
|
case "ORDER_BUYER_VIEW_ANNOUNCE_SENDGOODS": //发货
|
|
|
case "ORDER_BUYER_VIEW_ANNOUNCE_SENDGOODS": //发货
|
|
|
DeliveryCallbackFrom1688(jObject, _1688ConcurrentKey); |
|
|
DeliveryCallbackFrom1688(jObject); |
|
|
break; |
|
|
break; |
|
|
case "ORDER_BUYER_VIEW_ORDER_PRICE_MODIFY": |
|
|
case "ORDER_BUYER_VIEW_ORDER_PRICE_MODIFY": |
|
|
OrderPriceModificationCallbackFrom1688(jObject, _1688ConcurrentKey); //订单改价
|
|
|
OrderPriceModificationCallbackFrom1688(jObject); //订单改价
|
|
|
break; |
|
|
break; |
|
|
case "LOGISTICS_BUYER_VIEW_TRACE": |
|
|
case "LOGISTICS_BUYER_VIEW_TRACE": |
|
|
// LogisticsUpdateCallbackFrom1688(jObject);//1688物流信息变更
|
|
|
// LogisticsUpdateCallbackFrom1688(jObject);//1688物流信息变更
|
|
|
break; |
|
|
break; |
|
|
case "ORDER_BUYER_VIEW_ORDER_PAY": |
|
|
case "ORDER_BUYER_VIEW_ORDER_PAY": |
|
|
OrderPayFrom1688(jObject, _1688ConcurrentKey); |
|
|
OrderPayFrom1688(jObject); |
|
|
break; |
|
|
break; |
|
|
default: |
|
|
default: |
|
|
break; |
|
|
break; |
|
@ -2416,21 +2416,19 @@ namespace BBWYB.Server.Business |
|
|
/// 1688发货回调
|
|
|
/// 1688发货回调
|
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
/// <param name="jObject"></param>
|
|
|
/// <param name="jObject"></param>
|
|
|
/// <param name="_1688ConcurrentKey">并发key</param>
|
|
|
private void DeliveryCallbackFrom1688(JObject jObject) |
|
|
private void DeliveryCallbackFrom1688(JObject jObject, string _1688ConcurrentKey) |
|
|
|
|
|
{ |
|
|
{ |
|
|
var purchaseOrderId = jObject["data"].Value<string>("orderId"); |
|
|
var purchaseOrderId = jObject["data"].Value<string>("orderId"); |
|
|
Task.Factory.StartNew(() => DeliveryCallbackFrom1688(purchaseOrderId, _1688ConcurrentKey), CancellationToken.None, TaskCreationOptions.LongRunning, taskSchedulerManager.PurchaseOrderCallbackTaskScheduler); |
|
|
Task.Factory.StartNew(() => DeliveryCallbackFrom1688(purchaseOrderId), CancellationToken.None, TaskCreationOptions.LongRunning, taskSchedulerManager.PurchaseOrderCallbackTaskScheduler); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
|
/// 1688发货回调
|
|
|
/// 1688发货回调
|
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
/// <param name="purchaseOrderId"></param>
|
|
|
/// <param name="purchaseOrderId"></param>
|
|
|
/// <param name="_1688ConcurrentKey"></param>
|
|
|
|
|
|
/// <exception cref="Exception"></exception>
|
|
|
/// <exception cref="Exception"></exception>
|
|
|
/// <exception cref="BusinessException"></exception>
|
|
|
/// <exception cref="BusinessException"></exception>
|
|
|
private void DeliveryCallbackFrom1688(string purchaseOrderId, string _1688ConcurrentKey) |
|
|
private void DeliveryCallbackFrom1688(string purchaseOrderId) |
|
|
{ |
|
|
{ |
|
|
string orderId = string.Empty; |
|
|
string orderId = string.Empty; |
|
|
long? shopId = null; |
|
|
long? shopId = null; |
|
@ -2668,11 +2666,6 @@ namespace BBWYB.Server.Business |
|
|
{ |
|
|
{ |
|
|
nLogManager.Default().Error(ex, $"DeliveryCallback 回调平台1688,订单号{orderId},采购单号{purchaseOrderId},执行进度[{currentProgress}],采购单物流信息:{wayBillNoResponseInfo}"); |
|
|
nLogManager.Default().Error(ex, $"DeliveryCallback 回调平台1688,订单号{orderId},采购单号{purchaseOrderId},执行进度[{currentProgress}],采购单物流信息:{wayBillNoResponseInfo}"); |
|
|
} |
|
|
} |
|
|
finally |
|
|
|
|
|
{ |
|
|
|
|
|
if (!string.IsNullOrEmpty(_1688ConcurrentKey)) |
|
|
|
|
|
memoryCache.Remove(_1688ConcurrentKey); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
@ -2680,16 +2673,16 @@ namespace BBWYB.Server.Business |
|
|
/// </summary>
|
|
|
/// </summary>
|
|
|
/// <param name="jObject"></param>
|
|
|
/// <param name="jObject"></param>
|
|
|
/// <param name="_1688ConcurrentKey"></param>
|
|
|
/// <param name="_1688ConcurrentKey"></param>
|
|
|
private void OrderPriceModificationCallbackFrom1688(JObject jObject, string _1688ConcurrentKey) |
|
|
private void OrderPriceModificationCallbackFrom1688(JObject jObject) |
|
|
{ |
|
|
{ |
|
|
var purchaseOrderId = jObject["data"].Value<string>("orderId"); |
|
|
var purchaseOrderId = jObject["data"].Value<string>("orderId"); |
|
|
Task.Factory.StartNew(() => OrderPriceModificationCallback(purchaseOrderId, Enums.Platform.阿里巴巴, _1688ConcurrentKey), CancellationToken.None, TaskCreationOptions.LongRunning, taskSchedulerManager.PurchaseOrderCallbackTaskScheduler); |
|
|
Task.Factory.StartNew(() => OrderPriceModificationCallback(purchaseOrderId, Enums.Platform.阿里巴巴), CancellationToken.None, TaskCreationOptions.LongRunning, taskSchedulerManager.PurchaseOrderCallbackTaskScheduler); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private void OrderPayFrom1688(JObject jObject, string _1688ConcurrentKey) |
|
|
private void OrderPayFrom1688(JObject jObject) |
|
|
{ |
|
|
{ |
|
|
var purchaseOrderId = jObject["data"].Value<string>("orderId"); |
|
|
var purchaseOrderId = jObject["data"].Value<string>("orderId"); |
|
|
Task.Factory.StartNew(() => OrderPayCallback(purchaseOrderId, Enums.Platform.阿里巴巴, _1688ConcurrentKey), CancellationToken.None, TaskCreationOptions.LongRunning, taskSchedulerManager.PurchaseOrderCallbackTaskScheduler); |
|
|
Task.Factory.StartNew(() => OrderPayCallback(purchaseOrderId, Enums.Platform.阿里巴巴), CancellationToken.None, TaskCreationOptions.LongRunning, taskSchedulerManager.PurchaseOrderCallbackTaskScheduler); |
|
|
} |
|
|
} |
|
|
#endregion
|
|
|
#endregion
|
|
|
|
|
|
|
|
@ -2700,9 +2693,9 @@ namespace BBWYB.Server.Business |
|
|
/// <param name="purchaseOrderId"></param>
|
|
|
/// <param name="purchaseOrderId"></param>
|
|
|
/// <param name="callbackPlatform"></param>
|
|
|
/// <param name="callbackPlatform"></param>
|
|
|
/// <param name="concurrentKey"></param>
|
|
|
/// <param name="concurrentKey"></param>
|
|
|
private void OrderPriceModificationCallback(string purchaseOrderId, Enums.Platform callbackPlatform, string concurrentKey) |
|
|
private void OrderPriceModificationCallback(string purchaseOrderId, Enums.Platform callbackPlatform) |
|
|
{ |
|
|
{ |
|
|
OnSomeOnePurchaseOrderChanged(purchaseOrderId, true, concurrentKey); |
|
|
OnSomeOnePurchaseOrderChanged(purchaseOrderId, true); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
/// <summary>
|
|
@ -2711,9 +2704,9 @@ namespace BBWYB.Server.Business |
|
|
/// <param name="purchaseOrderId"></param>
|
|
|
/// <param name="purchaseOrderId"></param>
|
|
|
/// <param name="callbackPlatform"></param>
|
|
|
/// <param name="callbackPlatform"></param>
|
|
|
/// <param name="concurrentKey"></param>
|
|
|
/// <param name="concurrentKey"></param>
|
|
|
private void OrderPayCallback(string purchaseOrderId, Enums.Platform callbackPlatform, string concurrentKey) |
|
|
private void OrderPayCallback(string purchaseOrderId, Enums.Platform callbackPlatform) |
|
|
{ |
|
|
{ |
|
|
OnSomeOnePurchaseOrderChanged(purchaseOrderId, false, concurrentKey); |
|
|
OnSomeOnePurchaseOrderChanged(purchaseOrderId, false); |
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public void KuaiDi100Publish(string param) |
|
|
public void KuaiDi100Publish(string param) |
|
@ -2986,7 +2979,7 @@ namespace BBWYB.Server.Business |
|
|
/// <param name="purchaseOrderId">采购单Id</param>
|
|
|
/// <param name="purchaseOrderId">采购单Id</param>
|
|
|
/// <param name="keepRunWhenNoEditOrderPirce">当不需要触发订单改价时是否继续走流程</param>
|
|
|
/// <param name="keepRunWhenNoEditOrderPirce">当不需要触发订单改价时是否继续走流程</param>
|
|
|
/// <param name="concurrentKey">并发key</param>
|
|
|
/// <param name="concurrentKey">并发key</param>
|
|
|
public void OnSomeOnePurchaseOrderChanged(string purchaseOrderId, bool keepRunWhenNoEditOrderPirce, string concurrentKey) |
|
|
public void OnSomeOnePurchaseOrderChanged(string purchaseOrderId, bool keepRunWhenNoEditOrderPirce) |
|
|
{ |
|
|
{ |
|
|
bool isEditOrderPrice = true; |
|
|
bool isEditOrderPrice = true; |
|
|
try |
|
|
try |
|
@ -3241,11 +3234,6 @@ namespace BBWYB.Server.Business |
|
|
{ |
|
|
{ |
|
|
nLogManager.Default().Error(ex, $"OrderPriceModificationCallback 采购单号{purchaseOrderId}"); |
|
|
nLogManager.Default().Error(ex, $"OrderPriceModificationCallback 采购单号{purchaseOrderId}"); |
|
|
} |
|
|
} |
|
|
finally |
|
|
|
|
|
{ |
|
|
|
|
|
if (!string.IsNullOrEmpty(concurrentKey)) |
|
|
|
|
|
memoryCache.Remove(concurrentKey); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
private void SendDingDing(string content) |
|
|
private void SendDingDing(string content) |
|
|