wangxinhui
4 天以前 a0a0df2e824b6fe7e5a3c0afce78127fecf84fc9
ÏîÄ¿´úÂë/WCS/WCSServices/WIDESEAWCS_Tasks/Ô­ÁÏ¿â/ConveyorLineJob_YLOld.cs
@@ -78,7 +78,7 @@
                        R_ConveyorLineYLInfo conveyorLineInfoRead = device.Communicator.ReadCustomer<R_ConveyorLineYLInfo>(deviceProRead.DeviceProAddress);
                        if (conveyorLineInfoRead != null && item.StationType == StationTypeEnum.StationType_InStartAndOutEnd.ObjToInt() && conveyorLineInfoRead.WR_ToHode <= 0 && conveyorLineInfoRead.WR_Request == 86 && !string.IsNullOrEmpty(conveyorLineInfoRead.WR_TMID)) //老厂申请入库
                        {
                            WebResponseContent content = _taskService.YLPurchaseBoxing(conveyorLineInfoRead.WR_TMID, weight: conveyorLineInfoRead.WR_Weight, thickness: conveyorLineInfoRead.WR_Height, wide: conveyorLineInfoRead.WR_Width);
                            WebResponseContent content = _taskService.YLPurchaseBoxing(conveyorLineInfoRead.WR_TMID, weight: conveyorLineInfoRead.WR_Weight, thickness: conveyorLineInfoRead.WR_Height, wide: conveyorLineInfoRead.WR_Width, stationCode: item.StationCode);
                            if (content.Status)
                            {
                                device.SetValue(WR_CLineYLDB.WR_Reresult, 86, item.StationCode);
@@ -88,6 +88,20 @@
                            {
                                WriteError(item.StationCode, $"请求退料失败:{content.Message}");
                            }
                        }else if (conveyorLineInfoRead != null && item.StationType == StationTypeEnum.StationType_InStartAndOutEnd.ObjToInt() && conveyorLineInfoRead.WR_ToHode <= 0 && conveyorLineInfoRead.WR_Request == 98 && !string.IsNullOrEmpty(conveyorLineInfoRead.WR_TMID)) //老厂申请出库
                        {
                            Dt_Task task = _taskRepository.QueryFirst(x => _taskService.TaskOutboundTypes.Contains(x.TaskType) && x.TaskState == TaskStatusEnum.Line_Executing.ObjToInt() && x.DeviceCode == device.DeviceCode && x.RfidCode == conveyorLineInfoRead.WR_TMID);
                            if (task != null)
                            {
                                //任务回复
                                device.SetValue(WR_CLineYLDB.WR_Reresult, 98, item.StationCode);
                                _taskService.TaskCompleted(task.TaskNum);
                                WriteInfo(item.StationCode, $"任务号:{task.TaskNum},RIFD{conveyorLineInfoRead.WR_TMID}老厂房完成");
                            }
                            else
                            {
                                WriteError(item.StationCode, $"{conveyorLineInfoRead.WR_TMID}对应RFID任务不存在");
                            }
                        }
                    }
                    else