From 438a163b5eb1e8a40e7f39f46602962b7f95a6f6 Mon Sep 17 00:00:00 2001
From: xxyy <cathay_xy@163.com>
Date: 星期一, 10 三月 2025 15:52:35 +0800
Subject: [PATCH] 更新库存状态并清理相关缓存
---
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs | 76 +++++++++++++++++++-------------------
1 files changed, 38 insertions(+), 38 deletions(-)
diff --git a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
index 16bde53..ca89b74 100644
--- a/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
+++ b/Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
@@ -238,50 +238,50 @@
{
if (command.ConveyorLineBarcode != "NoRead")
{
- var config = _sys_ConfigService.GetByConfigKey("SYS_BASE", "ISFRINTRAY");
- if (config.ConfigValue == "1")
+ //var config = _sys_ConfigService.GetByConfigKey("SYS_BASE", "ISFRINTRAY");
+ //if (config.ConfigValue == "1")
+ //{
+ // Random random = new Random();
+ // var task = new Dt_Task()
+ // {
+ // CurrentAddress = childDeviceCode,
+ // Grade = 1,
+ // NextAddress = "2066",
+ // PalletCode = command.ConveyorLineBarcode,
+ // Roadway = "FR",
+ // SourceAddress = childDeviceCode,
+ // TargetAddress = "2066",
+ // TaskNum = random.Next(1,9999),
+ // TaskType = (int)TaskInboundTypeEnum.InTray,
+ // TaskState = (int)TaskInStatusEnum.Line_InExecuting,
+ // WMSId = 0
+ // };
+ // var taskCommand = MapTaskCommand(task, command);
+ // conveyorLine.SendCommand(taskCommand, childDeviceCode);
+ //}
+ //else
+ //{
+ var taskDTO = CreateEmptyTrayTaskDto(command.ConveyorLineBarcode, childDeviceCode);
+
+ if (_taskRepository.QueryFirst(x => x.PalletCode == taskDTO.PalletCode) != null)
{
- Random random = new Random();
- var task = new Dt_Task()
- {
- CurrentAddress = childDeviceCode,
- Grade = 1,
- NextAddress = "2066",
- PalletCode = command.ConveyorLineBarcode,
- Roadway = "FR",
- SourceAddress = childDeviceCode,
- TargetAddress = "2066",
- TaskNum = random.Next(1,9999),
- TaskType = (int)TaskInboundTypeEnum.InTray,
- TaskState = (int)TaskInStatusEnum.Line_InExecuting,
- WMSId = 0
- };
- var taskCommand = MapTaskCommand(task, command);
- conveyorLine.SendCommand(taskCommand, childDeviceCode);
+ WriteInfo(conveyorLine.DeviceName, "褰撳墠鎵樼洏瀛樺湪浠诲姟");
+ return;
}
- else
+
+ var content = CreateAndSendTask(taskDTO);
+ if (content.Status)
{
- var taskDTO = CreateEmptyTrayTaskDto(command.ConveyorLineBarcode, childDeviceCode);
-
- if (_taskRepository.QueryFirst(x => x.PalletCode == taskDTO.PalletCode) != null)
+ var task = _taskService.QueryConveyorLineTask(conveyorLine.DeviceCode, childDeviceCode);
+ if (task != null)
{
- WriteInfo(conveyorLine.DeviceName, "褰撳墠鎵樼洏瀛樺湪浠诲姟");
- return;
- }
-
- var content = CreateAndSendTask(taskDTO);
- if (content.Status)
- {
- var task = _taskService.QueryConveyorLineTask(conveyorLine.DeviceCode, childDeviceCode);
- if (task != null)
- {
- var taskCommand = MapTaskCommand(task, command);
- conveyorLine.SendCommand(taskCommand, childDeviceCode);
- //ConveyorLineSendFinish(conveyorLine, childDeviceCode, true);
- _taskService.UpdateTaskStatusToNext(task);
- }
+ var taskCommand = MapTaskCommand(task, command);
+ conveyorLine.SendCommand(taskCommand, childDeviceCode);
+ //ConveyorLineSendFinish(conveyorLine, childDeviceCode, true);
+ _taskService.UpdateTaskStatusToNext(task);
}
}
+ //}
}
}
--
Gitblit v1.9.3