| | |
| | | } |
| | | else |
| | | { |
| | | if(item.TaskType.GetTaskTypeGroup() == TaskTypeGroup.OutbondGroup) |
| | | if (item.TaskType.GetTaskTypeGroup() == TaskTypeGroup.OutbondGroup) |
| | | { |
| | | List<Dt_Router> routers = _routerRepository.QueryData(x => x.InOutType == item.TaskType && item.AGVArea == x.NextPosi); |
| | | if (routers.FirstOrDefault() == null) |
| | |
| | | |
| | | task.NextAddress = router?.StartPosi ?? ""; |
| | | task.DeviceCode = item.RoadWay; |
| | | task.TaskState = TaskStatusEnum.SC_Execute.ObjToInt(); |
| | | } |
| | | else |
| | | { |
| | |
| | | return WebResponseContent.Instance.Error($"æªæ¾å°è·¯ç±é
置信æ¯"); |
| | | } |
| | | router = routers.FirstOrDefault(); |
| | | string stationCode = router?.NextPosi ?? ""; |
| | | Dt_StationManger? stationManger = _stationMangerRepository.QueryFirst(x => x.StationCode == stationCode); |
| | | if (stationManger == null) |
| | | { |
| | | return WebResponseContent.Instance.Error($"æªæ¾å°ç«å°é
置信æ¯"); |
| | | } |
| | | |
| | | task.NextAddress = router?.NextPosi ?? ""; |
| | | task.NextAddress = stationManger?.AGVStationCode ?? ""; |
| | | task.DeviceCode = "AGV"; |
| | | task.TaskState = TaskStatusEnum.AGV_Execute.ObjToInt(); |
| | | } |
| | | } |
| | | |