肖洋
2024-12-09 ad6f399066a747aeaba987360bce9ee40227302c
Code Management/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineJob_GW/GWTask/RequestInbound.cs
@@ -72,6 +72,7 @@
                    }
                    break;
                case 1:
                case 6:
                case 10:
                    ExecuteStationAction(stationManager, conveyorLine, command, childDeviceCode);
                    break;
@@ -155,10 +156,13 @@
                case 12:
                    ConveyorLineOutFinish(conveyorLine, command, childDeviceCode);
                    break;
                case 6:
                    CreateAndSendEmptyTrayTask(conveyorLine,command, childDeviceCode);
                    break;
                case 1:
                    if (stationManager.stationArea.Contains("GW"))
                    {
                        var taskGW = _taskRepository.QueryFirst(x => x.TargetAddress == childDeviceCode && x.TaskState == (int)TaskOutStatusEnum.OutFinish);
                        var taskGW = _taskRepository.QueryFirst(x => x.TargetAddress == childDeviceCode && (x.TaskState == (int)TaskOutStatusEnum.OutFinish|| x.TaskState == (int)TaskOutStatusEnum.OutPending));
                        if (taskGW != null)
                        {
                            command.ConveyorLineBarcode = taskGW.PalletCode;
@@ -277,7 +281,7 @@
        /// </summary>
        private async void RequestWmsTask(CommonConveyorLine_GW conveyorLine, ConveyorLineTaskCommand_After command, string childDeviceCode)
        {
            var taskGW = _taskRepository.QueryFirst(x => x.TargetAddress == childDeviceCode && x.TaskState == (int)TaskOutStatusEnum.OutFinish);
            var taskGW = _taskRepository.QueryFirst(x => x.TargetAddress == childDeviceCode && (x.TaskState == (int)TaskOutStatusEnum.OutFinish || x.TaskState == (int)TaskOutStatusEnum.OutPending));
            if (taskGW != null)
                _taskRepository.DeleteData(taskGW);
            var content = await _taskService.RequestWMSTask(command.ConveyorLineBarcode, childDeviceCode);