肖洋
2025-01-19 d59b540dd78d49ddf1f2e1c6dfb7b19a7d3e3d7c
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
@@ -238,29 +238,29 @@
        {
            if (command.ConveyorLineBarcode != "NoRead")
            {
                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 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)
@@ -281,7 +281,7 @@
                            _taskService.UpdateTaskStatusToNext(task);
                        }
                    }
                }
                //}
            }
        }