dengjunjie
2024-10-30 680ccbedf08839143215f40dea5273dc2819100c
ÏîÄ¿´úÂë/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs
@@ -104,6 +104,8 @@
                                        }
                                        else
                                        {
                                            task.ShuttleCarCode = ShuttleCar?.ShuttleCarCode;
                                            _taskService.UpdateData(task);
                                            SendTask(commonStackerCrane, task);//下发堆垛机任务
                                        }
                                    }
@@ -130,7 +132,7 @@
            if (stackerCraneTaskCommand != null)
            {
                bool sendFlag = commonStackerCrane.SendCommand(stackerCraneTaskCommand);
                bool worktype = commonStackerCrane.SetValue(StackerCraneDBName.WorkType, task.TaskType == (int)TaskOtherTypeEnum.RelocationCar ? 2 : 1);
                bool worktype = commonStackerCrane.SetValue(StackerCraneDBName.WorkType, task.TaskType == (int)TaskOtherTypeEnum.RelocationCar ? (short)WorkType.Car : (short)WorkType.Cargo);
                if (sendFlag && worktype)
                {
                    if (commonStackerCrane.SetValue(StackerCraneDBName.CommandSend, sendFlag))
@@ -226,7 +228,7 @@
                    task = _taskService.QueryStackerCraneInTask(commonStackerCrane.DeviceCode);
                }
            }
            if (task != null && task.TargetAddress != "SC01") return task;//入库任务判断是否已分配货位,WMS判断货位状态是否允许放货
            if (task != null && !string.IsNullOrEmpty(task.TargetAddress)) return task;//入库任务判断是否已分配货位,WMS判断货位状态是否允许放货
            return task;
        }
@@ -271,10 +273,7 @@
        {
            StackerCraneTaskCommandW stackerCraneTaskCommand = new StackerCraneTaskCommandW();
            stackerCraneTaskCommand.Barcode = task.PalletCode;
            stackerCraneTaskCommand.TaskNum = task.TaskNum;
            stackerCraneTaskCommand.WorkType = (short)WorkType.Cargo;
            stackerCraneTaskCommand.TrayType = 0;
            if (task.TaskType.GetTaskTypeGroup() == TaskTypeGroup.InboundGroup)//判断是否是入库任务
            {
                List<Dt_Router> routers = _routerService.QueryNextRoutes(task.CurrentAddress, task.Roadway);