|
@ -1,5 +1,7 @@ |
|
|
|
|
|
using System; |
|
|
using System.Collections.Generic; |
|
|
using System.Collections.Generic; |
|
|
using System.Text.Json; |
|
|
using System.Text.Json; |
|
|
|
|
|
using System.Threading; |
|
|
using System.Threading.Tasks; |
|
|
using System.Threading.Tasks; |
|
|
using Microsoft.Extensions.DependencyInjection; |
|
|
using Microsoft.Extensions.DependencyInjection; |
|
|
using Volo.Abp.BackgroundWorkers; |
|
|
using Volo.Abp.BackgroundWorkers; |
|
@ -8,7 +10,6 @@ using Win_in.Sfs.Auth.Users; |
|
|
using Win_in.Sfs.Auth.Users.Inputs; |
|
|
using Win_in.Sfs.Auth.Users.Inputs; |
|
|
using Win_in.Sfs.Basedata.Application.Contracts; |
|
|
using Win_in.Sfs.Basedata.Application.Contracts; |
|
|
using Win_in.Sfs.Label.Application.Contracts; |
|
|
using Win_in.Sfs.Label.Application.Contracts; |
|
|
using Win_in.Sfs.Shared.Domain.Shared; |
|
|
|
|
|
using Win_in.Sfs.Wms.DataExchange.Domain; |
|
|
using Win_in.Sfs.Wms.DataExchange.Domain; |
|
|
using Win_in.Sfs.Wms.Inventory.Application.Contracts; |
|
|
using Win_in.Sfs.Wms.Inventory.Application.Contracts; |
|
|
using Win_in.Sfs.Wms.Store.Application.Contracts; |
|
|
using Win_in.Sfs.Wms.Store.Application.Contracts; |
|
@ -54,6 +55,25 @@ public static class IncomingToWmsExtensions |
|
|
var item = JsonSerializer.Deserialize<ItemBasicEditInput>(incomingConverted.DataContent); |
|
|
var item = JsonSerializer.Deserialize<ItemBasicEditInput>(incomingConverted.DataContent); |
|
|
var itemBasicAppService = workerContext.ServiceProvider.GetRequiredService<IItemBasicAppService>(); |
|
|
var itemBasicAppService = workerContext.ServiceProvider.GetRequiredService<IItemBasicAppService>(); |
|
|
await itemBasicAppService.UpsertAsyncByInterface(item).ConfigureAwait(false); |
|
|
await itemBasicAppService.UpsertAsyncByInterface(item).ConfigureAwait(false); |
|
|
|
|
|
|
|
|
|
|
|
try |
|
|
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
var BalanceAppService = workerContext.ServiceProvider.GetRequiredService<IBalanceAppService>(); |
|
|
|
|
|
BalanceUpdateItemBasicInfoDto balan = new BalanceUpdateItemBasicInfoDto(); |
|
|
|
|
|
BalanceUpdateItemBasicInfo bala = new BalanceUpdateItemBasicInfo(); |
|
|
|
|
|
bala.ItemCode = item.Code; |
|
|
|
|
|
bala.ItemDesc1 = item.Desc1; |
|
|
|
|
|
bala.ItemDesc2 = item.Desc2; |
|
|
|
|
|
balan.BalanceUpdateItemBasicInfos.Add(bala); |
|
|
|
|
|
await BalanceAppService.UpdateItemBasicInfoAsync(balan).ConfigureAwait(false); |
|
|
|
|
|
} |
|
|
|
|
|
catch (Exception e) |
|
|
|
|
|
{ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
public static async Task HandleErpLocationsAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) |
|
|
public static async Task HandleErpLocationsAsync(this IncomingToWms incomingConverted, PeriodicBackgroundWorkerContext workerContext) |
|
|