From 4d83bc8431bb1fda7b3cef959e2505b2402285d2 Mon Sep 17 00:00:00 2001 From: hutongqing <hutongqing@hnkhzn.com> Date: 星期四, 26 十二月 2024 21:53:14 +0800 Subject: [PATCH] · --- 代码管理/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/144011e2-42f0-4bb3-91f4-4f3faf1287db.vsidx | 0 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/WIDESEAWCS_Tasks.csproj | 10 ++- 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs | 1 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Service/AssignLocation/LocationInfoService_CSJ.cs | 3 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/油墨仓/StackerCraneJob_YM.cs | 30 +++++++++- 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3273c20c-b49e-4f5e-9b68-3a0c163bfb0d.vsidx | 0 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Reloaction.cs | 3 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/HostedService/WarehouseHostedService.cs | 4 + /dev/null | 0 代码管理/WMS/WIDESEA_WMSServer/WIDESEA_External/ERPService/InvokeERPService.cs | 4 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Common/APIEnum/APIEnum.cs | 23 +++++++ 项目资料/设备协议/干膜仓堆垛机通信协议.xlsx | 0 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/Program.cs | 2 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/测试架仓/StackerCraneJob_CSJ.cs | 78 +++++++++++++++++++++----- 代码管理/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/82bf8887-9a08-48ab-8128-b1344527468e.vsidx | 0 代码管理/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs | 18 ++++++ 16 files changed, 148 insertions(+), 28 deletions(-) diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/144011e2-42f0-4bb3-91f4-4f3faf1287db.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/144011e2-42f0-4bb3-91f4-4f3faf1287db.vsidx" new file mode 100644 index 0000000..a28b4f9 --- /dev/null +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/144011e2-42f0-4bb3-91f4-4f3faf1287db.vsidx" Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/6dfb708c-1dce-481d-8fd0-9391b26c11ff.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/6dfb708c-1dce-481d-8fd0-9391b26c11ff.vsidx" deleted file mode 100644 index 5481cd1..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/.vs/WIDESEAWCS_Server/FileContentIndex/6dfb708c-1dce-481d-8fd0-9391b26c11ff.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Common/APIEnum/APIEnum.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Common/APIEnum/APIEnum.cs" index 102375d..6f9e592 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Common/APIEnum/APIEnum.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Common/APIEnum/APIEnum.cs" @@ -9,13 +9,34 @@ { public enum APIEnum { + /// <summary> + /// AGV鍙戦�佷换鍔℃帴鍙� + /// </summary> [Description("AGV鍙戦�佷换鍔℃帴鍙�")] AgvSendTask, + + /// <summary> + /// AGV瀹夊叏淇″彿鍥炲 + /// </summary> [Description("AGV瀹夊叏淇″彿鍥炲")] AgvSecureReply, + /// <summary> + /// 鍥炶皟WMS浠诲姟瀹屾垚 + /// </summary> + [Description("鍥炶皟WMS浠诲姟瀹屾垚")] FeedBackWMSTaskCompleted, - UploadWMSTaskStatus + /// <summary> + /// 涓婃姤WMS浠诲姟鐘舵�� + /// </summary> + [Description("涓婃姤WMS浠诲姟鐘舵��")] + UploadWMSTaskStatus, + + /// <summary> + /// WMS鏄惁绉诲簱鍒ゆ柇 + /// </summary> + [Description("WMS鏄惁绉诲簱鍒ゆ柇")] + WMSIsReloaction } } diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/HostedService/WarehouseHostedService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/HostedService/WarehouseHostedService.cs" index 390d476..64b2c52 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/HostedService/WarehouseHostedService.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/HostedService/WarehouseHostedService.cs" @@ -39,6 +39,10 @@ _dbContext.Db.Insertable(warehouses).ExecuteCommand(); + List<Dt_ApiInfo> apiInfos = _dbContext.Db.Queryable<Dt_ApiInfo>().ToList(); + + _cacheService.AddOrUpdate(nameof(apiInfos), apiInfos); + return Task.CompletedTask; } diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/Program.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/Program.cs" index 17424c7..0f850ff 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/Program.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Server/Program.cs" @@ -63,7 +63,7 @@ builder.Services.AddHttpContextSetup(); -//builder.Services.AddHostedService<QuartzJobHostedService>(); +builder.Services.AddHostedService<QuartzJobHostedService>(); builder.Services.AddMvc(options => { diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs" index 7021a70..35f3322 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_TaskInfoService/TaskService.cs" @@ -87,6 +87,24 @@ } + public WebResponseContent TaskCompleted(int taskNum) + { + try + { + Dt_Task task = BaseDal.QueryFirst(x => x.TaskNum == taskNum); + if (task != null) + { + + } + + return WebResponseContent.Instance.OK(); + } + catch (Exception ex) + { + return WebResponseContent.Instance.Error(ex.Message); + } + } + /// <summary> /// 鎺ユ敹WMS浠诲姟淇℃伅 /// </summary> diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/WIDESEAWCS_Tasks.csproj" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/WIDESEAWCS_Tasks.csproj" index e635b36..60d817d 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/WIDESEAWCS_Tasks.csproj" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/WIDESEAWCS_Tasks.csproj" @@ -7,15 +7,17 @@ </PropertyGroup> <ItemGroup> + <Compile Remove="HoisterJob\**" /> + <EmbeddedResource Remove="HoisterJob\**" /> + <None Remove="HoisterJob\**" /> + </ItemGroup> + + <ItemGroup> <PackageReference Include="WIDESEAWCS_QuartzJob" Version="3.0.1" /> </ItemGroup> <ItemGroup> <ProjectReference Include="..\WIDESEAWCS_TaskInfoService\WIDESEAWCS_TaskInfoService.csproj" /> - </ItemGroup> - - <ItemGroup> - <Folder Include="HoisterJob\" /> </ItemGroup> </Project> diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\262\271\345\242\250\344\273\223/StackerCraneJob_YM.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\262\271\345\242\250\344\273\223/StackerCraneJob_YM.cs" index 17fbe79..61684c3 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\262\271\345\242\250\344\273\223/StackerCraneJob_YM.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\262\271\345\242\250\344\273\223/StackerCraneJob_YM.cs" @@ -1,4 +1,5 @@ 锘縰sing Microsoft.AspNetCore.Components.Routing; +using Newtonsoft.Json; using Quartz; using System; using System.Collections.Generic; @@ -6,8 +7,10 @@ using System.Linq; using System.Text; using System.Threading.Tasks; +using WIDESEAWCS_Common.APIEnum; using WIDESEAWCS_Common.TaskEnum; using WIDESEAWCS_Core; +using WIDESEAWCS_Core.Caches; using WIDESEAWCS_Core.Enums; using WIDESEAWCS_Core.Helper; using WIDESEAWCS_IBasicInfoRepository; @@ -30,19 +33,32 @@ [DisallowConcurrentExecution] public class StackerCraneJob_YM : JobBase, IJob { + private readonly ICacheService _cacheService; private readonly ITaskService _taskService; private readonly ITaskExecuteDetailService _taskExecuteDetailService; private readonly ITaskRepository _taskRepository; private readonly IRouterService _routerService; private readonly IStationMangerRepository _stationMangerRepository; + private List<Dt_ApiInfo> apiInfos; - public StackerCraneJob_YM(ITaskService taskService, ITaskExecuteDetailService taskExecuteDetailService, ITaskRepository taskRepository, IRouterService routerService, IStationMangerRepository stationMangerRepository) + public StackerCraneJob_YM(ITaskService taskService, ICacheService cacheService, ITaskExecuteDetailService taskExecuteDetailService, ITaskRepository taskRepository, IRouterService routerService, IStationMangerRepository stationMangerRepository) { + _cacheService = cacheService; _taskService = taskService; _taskExecuteDetailService = taskExecuteDetailService; _taskRepository = taskRepository; _routerService = routerService; _stationMangerRepository = stationMangerRepository; + + string? apiInfoStr = _cacheService.Get("apiInfos"); + if (!string.IsNullOrEmpty(apiInfoStr)) + { + apiInfos = JsonConvert.DeserializeObject<List<Dt_ApiInfo>>(apiInfoStr); + if (apiInfos == null || apiInfos.Count == 0) + { + apiInfos = new List<Dt_ApiInfo>(); + } + } } public Task Execute(IJobExecutionContext context) @@ -102,9 +118,17 @@ Dt_Task task = _taskRepository.QueryFirst(x => x.TaskNum == e.TaskNum); if (task != null) { + string? url = apiInfos.FirstOrDefault(x => x.ApiCode == APIEnum.FeedBackWMSTaskCompleted.ToString())?.ApiAddress; + if (string.IsNullOrEmpty(url)) + { + _taskExecuteDetailService.AddTaskExecuteDetail(e.TaskNum, $"鏈壘鍒板洖璋僕MS浠诲姟瀹屾垚鎺ュ彛"); + WriteInfo(commonStackerCrane.DeviceName, $"鏈壘鍒板洖璋僕MS浠诲姟瀹屾垚鎺ュ彛"); + return; + } + + HttpHelper.Post($"{url}?taskNum={e.TaskNum}", "");//todo 璋冪敤WMS浠诲姟瀹屾垚鏂规硶 _taskExecuteDetailService.AddTaskExecuteDetail(e.TaskNum, $"绯荤粺鑷姩娴佺▼,浠诲姟瀹屾垚"); _taskRepository.DeleteAndMoveIntoHty(task, OperateTypeEnum.鑷姩瀹屾垚); - HttpHelper.Post("", "");//todo 璋冪敤WMS浠诲姟瀹屾垚鏂规硶 } else { @@ -187,7 +211,7 @@ OtherDevice client = (OtherDevice)device; if (client.GetValue<GroundStationDBName, bool>(GroundStationDBName.R_IsCanPut, stationManger.StationCode))//鍑哄簱绔欏彴鏈鍗犵敤 { - task.TargetAddress = stationManger.StackerCraneStationCode; + task.NextAddress = stationManger.StackerCraneStationCode; _taskRepository.UpdateData(task); return task; } diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\265\213\350\257\225\346\236\266\344\273\223/StackerCraneJob_CSJ.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\265\213\350\257\225\346\236\266\344\273\223/StackerCraneJob_CSJ.cs" index c96fb0f..2911a93 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\265\213\350\257\225\346\236\266\344\273\223/StackerCraneJob_CSJ.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/\346\265\213\350\257\225\346\236\266\344\273\223/StackerCraneJob_CSJ.cs" @@ -1,4 +1,5 @@ 锘縰sing Microsoft.AspNetCore.Components.Routing; +using Newtonsoft.Json; using Quartz; using System; using System.Collections.Generic; @@ -6,8 +7,10 @@ using System.Linq; using System.Text; using System.Threading.Tasks; +using WIDESEAWCS_Common.APIEnum; using WIDESEAWCS_Common.TaskEnum; using WIDESEAWCS_Core; +using WIDESEAWCS_Core.Caches; using WIDESEAWCS_Core.Enums; using WIDESEAWCS_Core.Helper; using WIDESEAWCS_IBasicInfoRepository; @@ -27,19 +30,36 @@ [DisallowConcurrentExecution] public class StackerCraneJob_CSJ : JobBase, IJob { + private readonly ICacheService _cacheService; private readonly ITaskService _taskService; private readonly ITaskExecuteDetailService _taskExecuteDetailService; private readonly ITaskRepository _taskRepository; private readonly IRouterService _routerService; private readonly IStationMangerRepository _stationMangerRepository; + private List<Dt_ApiInfo> apiInfos; - public StackerCraneJob_CSJ(ITaskService taskService, ITaskExecuteDetailService taskExecuteDetailService, ITaskRepository taskRepository, IRouterService routerService, IStationMangerRepository stationMangerRepository) + public StackerCraneJob_CSJ(ITaskService taskService, ICacheService cacheService, ITaskExecuteDetailService taskExecuteDetailService, ITaskRepository taskRepository, IRouterService routerService, IStationMangerRepository stationMangerRepository) { _taskService = taskService; _taskExecuteDetailService = taskExecuteDetailService; _taskRepository = taskRepository; _routerService = routerService; _stationMangerRepository = stationMangerRepository; + _cacheService = cacheService; + + string? apiInfoStr = _cacheService.Get("apiInfos"); + if (!string.IsNullOrEmpty(apiInfoStr)) + { + List<Dt_ApiInfo>? infos = JsonConvert.DeserializeObject<List<Dt_ApiInfo>>(apiInfoStr); + if (infos == null || infos.Count == 0) + { + apiInfos = new List<Dt_ApiInfo>(); + } + else + { + apiInfos = infos; + } + } } public Task Execute(IJobExecutionContext context) @@ -101,13 +121,13 @@ if (commonStackerCrane.GetValue<StackerCraneDBName, short>(StackerCraneDBName.WorkType) != 5) { Console.Out.WriteLine("TaskCompleted" + e.TaskNum); - StackerCraneTaskCompleted(e.TaskNum, commonStackerCrane.DeviceName); + StackerCraneTaskCompleted(e.TaskNum, commonStackerCrane.DeviceCode); commonStackerCrane.SetValue(StackerCraneDBName.WorkType, 5); } } } - public WebResponseContent StackerCraneTaskCompleted(int taskNum, string deviceName) + public WebResponseContent StackerCraneTaskCompleted(int taskNum, string deviceCode) { try { @@ -124,16 +144,30 @@ _taskRepository.UpdateData(task); _taskExecuteDetailService.AddTaskExecuteDetail(taskNum, $"绯荤粺鑷姩娴佺▼,锛屼换鍔$姸鎬佷粠銆恵oldStatus}銆戣浆鍒般�恵task.TaskState}銆�"); } - else if (task.TaskType.GetTaskTypeGroup() != TaskTypeGroup.InboundGroup) + else if (task.TaskType.GetTaskTypeGroup() != TaskTypeGroup.InboundGroup || task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.RelocationGroup) { - _taskExecuteDetailService.AddTaskExecuteDetail(taskNum, $"绯荤粺鑷姩娴佺▼,锛屼换鍔″畬鎴�"); + string? url = apiInfos.FirstOrDefault(x => x.ApiCode == APIEnum.FeedBackWMSTaskCompleted.ToString())?.ApiAddress; + if (string.IsNullOrEmpty(url)) + { + _taskExecuteDetailService.AddTaskExecuteDetail(taskNum, $"鏈壘鍒板洖璋僕MS浠诲姟瀹屾垚鎺ュ彛"); + WriteInfo(deviceCode, $"鏈壘鍒板洖璋僕MS浠诲姟瀹屾垚鎺ュ彛"); + return WebResponseContent.Instance.Error(); + } + + HttpHelper.Post($"{url}?taskNum={taskNum}", "");//todo 璋冪敤WMS浠诲姟瀹屾垚鏂规硶 + _taskExecuteDetailService.AddTaskExecuteDetail(taskNum, $"绯荤粺鑷姩娴佺▼,浠诲姟瀹屾垚"); _taskRepository.DeleteAndMoveIntoHty(task, OperateTypeEnum.鑷姩瀹屾垚); - HttpHelper.Post("", "");//todo 璋冪敤WMS浠诲姟瀹屾垚鏂规硶 + } + else + { + WriteInfo(deviceCode, $"鏈壘鍒拌浠诲姟绫诲瀷鍥炶皟WMS浠诲姟瀹屾垚鎺ュ彛,{task.TaskType}"); + _taskExecuteDetailService.AddTaskExecuteDetail(taskNum, $"鏈壘鍒拌浠诲姟绫诲瀷鍥炶皟WMS浠诲姟瀹屾垚鎺ュ彛,{task.TaskType}"); + _taskService.UpdateTaskExceptionMessage(taskNum, $"鏈壘鍒拌浠诲姟绫诲瀷鍥炶皟WMS浠诲姟瀹屾垚鎺ュ彛,{task.TaskType}"); } } else { - WriteInfo(deviceName, $"鏈壘鍒颁换鍔′俊鎭�,浠诲姟鍙�:{taskNum}"); + WriteInfo(deviceCode, $"鏈壘鍒颁换鍔′俊鎭�,浠诲姟鍙�:{taskNum}"); return WebResponseContent.Instance.Error($"鏈壘鍒颁换鍔′俊鎭�,浠诲姟鍙�:{taskNum}"); } @@ -141,7 +175,7 @@ } catch (Exception ex) { - WriteError(deviceName, $"浠诲姟瀹屾垚閿欒", ex); + WriteError(deviceCode, $"浠诲姟瀹屾垚閿欒", ex); return WebResponseContent.Instance.Error(ex.Message); } } @@ -199,9 +233,17 @@ } } - if(task != null && task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.RelocationGroup) + if (task != null && task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.OutbondGroup) { - HttpHelper.Post("", ""); + string? url = apiInfos.FirstOrDefault(x => x.ApiCode == APIEnum.FeedBackWMSTaskCompleted.ToString())?.ApiAddress; + if (string.IsNullOrEmpty(url)) + { + _taskExecuteDetailService.AddTaskExecuteDetail(task.TaskNum, $"鏈壘鍒癢MS绉诲簱鍒ゆ柇鎺ュ彛"); + WriteInfo(commonStackerCrane.DeviceCode, $"鏈壘鍒癢MS绉诲簱鍒ゆ柇鎺ュ彛"); + _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"鏈壘鍒癢MS绉诲簱鍒ゆ柇鎺ュ彛"); + return null; + } + HttpHelper.Post($"{url}?taskNum={task.TaskNum}&locationCode={task.NextAddress}", "");//todo 璋冪敤WMS浠诲姟瀹屾垚鏂规硶 } return task; @@ -223,7 +265,7 @@ OtherDevice client = (OtherDevice)device; if (client.GetValue<GroundStationDBName, bool>(GroundStationDBName.R_IsCanPut, stationManger.StationCode))//鍑哄簱绔欏彴鏈鍗犵敤 { - task.TargetAddress = stationManger.StackerCraneStationCode; + task.NextAddress = stationManger.StackerCraneStationCode; _taskRepository.UpdateData(task); client.SetValue(GroundStationDBName.R_IsCanPut, true, stationManger.StationCode); return task; @@ -231,11 +273,13 @@ } else { + WriteInfo(task.DeviceCode, $"鏈壘鍒板嚭搴撶珯鍙般�恵stationManger.StationDeviceCode}銆戝搴旂殑閫氳瀵硅薄锛屾棤娉曞垽鏂嚭搴撶珯鍙版槸鍚﹁鍗犵敤"); _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"鏈壘鍒板嚭搴撶珯鍙般�恵stationManger.StationDeviceCode}銆戝搴旂殑閫氳瀵硅薄锛屾棤娉曞垽鏂嚭搴撶珯鍙版槸鍚﹁鍗犵敤"); } } else { + WriteInfo(task.DeviceCode, $"鏈壘鍒扮珯鍙般�恵task.NextAddress}銆戜俊鎭紝鏃犳硶鏍¢獙绔欏彴"); _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"鏈壘鍒扮珯鍙般�恵task.NextAddress}銆戜俊鎭紝鏃犳硶鏍¢獙绔欏彴"); } return null; @@ -264,7 +308,7 @@ stackerCraneTaskCommand.StartLayer = Convert.ToInt16(startCodes[2]); string[] targetCodes = task.NextAddress.Split("-"); - if (targetCodes.Length == 3) + if (targetCodes.Length == 5) { stackerCraneTaskCommand.EndRow = Convert.ToInt16(targetCodes[0]); stackerCraneTaskCommand.EndColumn = Convert.ToInt16(targetCodes[1]); @@ -274,6 +318,7 @@ { //鏁版嵁閰嶇疆閿欒 _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"鍏ュ簱浠诲姟缁堢偣閿欒锛岃捣鐐癸細銆恵task.NextAddress}銆�"); + WriteInfo(task.DeviceCode, $"鍏ュ簱浠诲姟缁堢偣閿欒锛岃捣鐐癸細銆恵task.NextAddress}銆�"); return null; } } @@ -286,7 +331,7 @@ stackerCraneTaskCommand.EndLayer = Convert.ToInt16(targetCodes[2]); string[] sourceCodes = task.CurrentAddress.Split("-"); - if (sourceCodes.Length == 3) + if (sourceCodes.Length == 5) { stackerCraneTaskCommand.StartRow = Convert.ToInt16(sourceCodes[0]); stackerCraneTaskCommand.StartColumn = Convert.ToInt16(sourceCodes[1]); @@ -296,13 +341,14 @@ { //鏁版嵁閰嶇疆閿欒 _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"鍑哄簱浠诲姟璧风偣閿欒锛岃捣鐐癸細銆恵task.CurrentAddress}銆�"); + WriteInfo(task.DeviceCode, $"鍑哄簱浠诲姟璧风偣閿欒锛岃捣鐐癸細銆恵task.CurrentAddress}銆�"); return null; } } else if (task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.RelocationGroup) { string[] targetCodes = task.NextAddress.Split("-"); - if (targetCodes.Length == 3) + if (targetCodes.Length == 5) { stackerCraneTaskCommand.EndRow = Convert.ToInt16(targetCodes[0]); stackerCraneTaskCommand.EndColumn = Convert.ToInt16(targetCodes[1]); @@ -312,10 +358,11 @@ { //鏁版嵁閰嶇疆閿欒 _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"绉诲簱浠诲姟缁堢偣閿欒锛岃捣鐐癸細銆恵task.NextAddress}銆�"); + WriteInfo(task.DeviceCode, $"绉诲簱浠诲姟缁堢偣閿欒锛岃捣鐐癸細銆恵task.NextAddress}銆�"); return null; } string[] sourceCodes = task.CurrentAddress.Split("-"); - if (sourceCodes.Length == 3) + if (sourceCodes.Length == 5) { stackerCraneTaskCommand.StartRow = Convert.ToInt16(sourceCodes[0]); stackerCraneTaskCommand.StartColumn = Convert.ToInt16(sourceCodes[1]); @@ -325,6 +372,7 @@ { //鏁版嵁閰嶇疆閿欒 _taskService.UpdateTaskExceptionMessage(task.TaskNum, $"绉诲簱浠诲姟璧风偣閿欒锛岃捣鐐癸細銆恵task.CurrentAddress}銆�"); + WriteInfo(task.DeviceCode, $"绉诲簱浠诲姟璧风偣閿欒锛岃捣鐐癸細銆恵task.CurrentAddress}銆�"); return null; } } diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3273c20c-b49e-4f5e-9b68-3a0c163bfb0d.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3273c20c-b49e-4f5e-9b68-3a0c163bfb0d.vsidx" new file mode 100644 index 0000000..e8fab44 --- /dev/null +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3273c20c-b49e-4f5e-9b68-3a0c163bfb0d.vsidx" Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3391ef1a-b377-4e97-8ef2-e56d3ee99c44.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3391ef1a-b377-4e97-8ef2-e56d3ee99c44.vsidx" deleted file mode 100644 index 0517ea6..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/3391ef1a-b377-4e97-8ef2-e56d3ee99c44.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/50a4a68c-d15a-4c06-92d2-58d3ca8fbb54.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/50a4a68c-d15a-4c06-92d2-58d3ca8fbb54.vsidx" deleted file mode 100644 index 51df82c..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/50a4a68c-d15a-4c06-92d2-58d3ca8fbb54.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/52d14652-9578-4d37-be69-82ece695e359.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/52d14652-9578-4d37-be69-82ece695e359.vsidx" deleted file mode 100644 index b9fd08a..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/52d14652-9578-4d37-be69-82ece695e359.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/6f175d71-07e6-45dd-8008-da0dcbb0a76c.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/6f175d71-07e6-45dd-8008-da0dcbb0a76c.vsidx" deleted file mode 100644 index e5fb3dc..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/6f175d71-07e6-45dd-8008-da0dcbb0a76c.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/82bf8887-9a08-48ab-8128-b1344527468e.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/82bf8887-9a08-48ab-8128-b1344527468e.vsidx" new file mode 100644 index 0000000..9b27507 --- /dev/null +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/82bf8887-9a08-48ab-8128-b1344527468e.vsidx" Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/9a102d22-50b2-4a33-9ca7-fb3c6c8dea03.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/9a102d22-50b2-4a33-9ca7-fb3c6c8dea03.vsidx" deleted file mode 100644 index ffeaaa1..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/9a102d22-50b2-4a33-9ca7-fb3c6c8dea03.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/cf601b15-8665-4e91-bf55-55e9b66ed6a7.vsidx" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/cf601b15-8665-4e91-bf55-55e9b66ed6a7.vsidx" deleted file mode 100644 index 70aef67..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/cf601b15-8665-4e91-bf55-55e9b66ed6a7.vsidx" +++ /dev/null Binary files differ diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/read.lock" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/read.lock" deleted file mode 100644 index e69de29..0000000 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/.vs/WIDESEA_WMSServer/FileContentIndex/read.lock" +++ /dev/null diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Service/AssignLocation/LocationInfoService_CSJ.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Service/AssignLocation/LocationInfoService_CSJ.cs" index ac15f3f..c3c44a5 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Service/AssignLocation/LocationInfoService_CSJ.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_BasicService/Service/AssignLocation/LocationInfoService_CSJ.cs" @@ -30,7 +30,8 @@ /// 4锛氱壒闀� <br/> /// 1鍜�2閮芥槸3娣憋紝涓斿彲浠ユ贩鏀俱�� <br/> /// 3鍜�4閮芥槸2娣憋紝涓斿彲浠ユ贩鏀俱�� <br/> - /// 绉诲簱鏃跺彧鑳芥槸鍚屼晶璐т綅銆� + /// 绉诲簱鏃跺彧鑳芥槸鍚屼晶璐т綅銆� <br/> + /// 6鎺�43鍒�13灞�---13灞備笉鍙敤 /// </summary> /// <param name="roadwayNo">宸烽亾鍙�</param> /// <param name="palletType"> diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_External/ERPService/InvokeERPService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_External/ERPService/InvokeERPService.cs" index 07a2ef7..da50203 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_External/ERPService/InvokeERPService.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_External/ERPService/InvokeERPService.cs" @@ -21,7 +21,7 @@ private readonly IApiInfoRepository _apiInfoRepository; public InvokeERPService(IApiInfoRepository apiInfoRepository) { - _apiInfoRepository= apiInfoRepository; + _apiInfoRepository = apiInfoRepository; } // 鍒涘缓涓�涓娇鐢ㄥ皬椹煎嘲鍛藉悕娉曠殑搴忓垪鍖栬缃� JsonSerializerSettings settings = new JsonSerializerSettings @@ -35,7 +35,7 @@ /// <returns></returns> public string InvokeMatReceiveApi(ERPReceiveModel receiveModel) { - Dt_ApiInfo apiInfo = _apiInfoRepository.QueryFirst(x=>x.ApiCode==APIEnum.InvokeErpApi.ToString()); + Dt_ApiInfo apiInfo = _apiInfoRepository.QueryFirst(x => x.ApiCode == APIEnum.InvokeMatReceiveApi.ToString()); ERPBaseModel<ERPReceiveModel> model = new ERPBaseModel<ERPReceiveModel>() { Data = receiveModel, diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs" index 9a79994..c02a048 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_InboundService/InboundOrderService.cs" @@ -401,6 +401,7 @@ } return content; } + public WebResponseContent MaterielGroup(int inboundOrderId, string palletCode, List<string> serNums) { try diff --git "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Reloaction.cs" "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Reloaction.cs" index bcc8769..cdccf92 100644 --- "a/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Reloaction.cs" +++ "b/\344\273\243\347\240\201\347\256\241\347\220\206/WMS/WIDESEA_WMSServer/WIDESEA_TaskInfoService/TaskService_Reloaction.cs" @@ -32,6 +32,7 @@ { return WebResponseContent.Instance.Error($"鏈壘鍒板搴旂殑璐т綅淇℃伅"); } + Dt_Task task = Repository.QueryFirst(x => x.TaskNum == taskNum); if (task == null) { @@ -57,7 +58,7 @@ Dt_Task taskTemp = Repository.QueryFirst(x => x.PalletCode == stockInfo.PalletCode); if (taskTemp != null) { - return WebResponseContent.Instance.OK(data: taskTemp); + return WebResponseContent.Instance.OK(data: _mapper.Map<WMSTaskDTO>(taskTemp)); } Dt_LocationInfo? newLocation = _basicService.LocationInfoService.AssignLocation(needRelocationItem.RoadwayNo, (PalletTypeEnum)task.PalletType, task.WarehouseId); diff --git "a/\351\241\271\347\233\256\350\265\204\346\226\231/\350\256\276\345\244\207\345\215\217\350\256\256/\345\271\262\350\206\234\344\273\223\345\240\206\345\236\233\346\234\272\351\200\232\344\277\241\345\215\217\350\256\256.xlsx" "b/\351\241\271\347\233\256\350\265\204\346\226\231/\350\256\276\345\244\207\345\215\217\350\256\256/\345\271\262\350\206\234\344\273\223\345\240\206\345\236\233\346\234\272\351\200\232\344\277\241\345\215\217\350\256\256.xlsx" index db32a12..8f5cd0a 100644 --- "a/\351\241\271\347\233\256\350\265\204\346\226\231/\350\256\276\345\244\207\345\215\217\350\256\256/\345\271\262\350\206\234\344\273\223\345\240\206\345\236\233\346\234\272\351\200\232\344\277\241\345\215\217\350\256\256.xlsx" +++ "b/\351\241\271\347\233\256\350\265\204\346\226\231/\350\256\276\345\244\207\345\215\217\350\256\256/\345\271\262\350\206\234\344\273\223\345\240\206\345\236\233\346\234\272\351\200\232\344\277\241\345\215\217\350\256\256.xlsx" Binary files differ -- Gitblit v1.9.3