| | |
| | | using SqlSugar; |
| | | using System.Collections.Generic; |
| | | using System.Diagnostics.CodeAnalysis; |
| | | using System.Threading.Tasks; |
| | | using WIDESEAWCS_BasicInfoService; |
| | | using WIDESEAWCS_Common; |
| | | using WIDESEAWCS_Common.LocationEnum; |
| | |
| | | using WIDESEAWCS_IBasicInfoService; |
| | | using WIDESEAWCS_ITaskInfoService; |
| | | using WIDESEAWCS_Model.Models; |
| | | using WIDESEAWCS_QuartzJob; |
| | | using WIDESEAWCS_QuartzJob.Models; |
| | | using WIDESEAWCS_QuartzJob.Service; |
| | | |
| | |
| | | { |
| | | List<object> objects = new List<object>(); |
| | | foreach (var item in taskDTOs) |
| | | { |
| | | { |
| | | foreach (var task in item.tasks) |
| | | { |
| | | #region 夿 |
| | |
| | | objects.Add(new |
| | | { |
| | | taskCode = task.taskCode, |
| | | Message = $"èµ·ç¹ä½ç½®ã{task.containerCode}ãå·²åå¨ä»»å¡" |
| | | Message = $"èµ·ç¹ä½ç½®ã{task.fromLocationCode}ãå·²åå¨ä»»å¡" |
| | | }); |
| | | continue; |
| | | //throw new Exception($"èµ·ç¹ä½ç½®ã{task.containerCode}ãå·²åå¨ä»»å¡"); |
| | |
| | | } |
| | | else if (getLocationInfo.WarehouseId == 5) |
| | | { |
| | | |
| | | //读åå
çµä¿¡å· |
| | | var device = Storage.Devices.FirstOrDefault(x => x.DeviceCode == "F1") as OtherDevice; |
| | | if (device == null) throw new Exception("æªæ¾å°1楼质æ£é¨è®¾å¤ä¿¡æ¯") ; |
| | | if (!device.IsConnected) throw new Exception("PLC1楼质æ£é¨è®¾å¤è¿æ¥å¤±è´¥"); |
| | | var sta = _stationMangerService.Repository.QueryData(x => x.Remark == "æååº"); |
| | | foreach (var item in sta) |
| | | { |
| | | bool value = device.GetValue<QualityInspectionCommandEnum,bool>(QualityInspectionCommandEnum.R_StockAvailableSymbol, item.StationCode); |
| | | list.Add(new |
| | | { |
| | | LoctionCode = item.StationCode, |
| | | LocationStatus = value?100:0, |
| | | EnableStatus = 0, |
| | | }); |
| | | } |
| | | content.OK(data: list); |
| | | } |
| | | } |
| | | catch (Exception ex) |