| | |
| | | { |
| | | WebResponseContent content = new WebResponseContent(); |
| | | // 判断需不需要去包装,不需要就去常温三 |
| | | var stationManagers = _stationManagerRepository.QueryData(x => x.stationPLC == "1018" && x.stationArea == "Cache"); |
| | | var station = stationManagers.Select(x => x.stationChildCode).ToList(); |
| | | var stationManagers = _stationManagerRepository.QueryData(x => x.stationPLC == "1018" && x.stationArea == "Cache" && x.productLine == input.ProductionLine); |
| | | |
| | | // 获取WCSip地址相关配置 |
| | | var wcsIpAddrss = GetWCSIpAddress(); |
| | | if (wcsIpAddrss == null) |
| | | { |
| | | throw new InvalidOperationException("WCS IP 未配置"); |
| | | } |
| | | //var station = stationManagers.Select(x => x.stationChildCode).ToList(); |
| | | |
| | | var abc = HttpHelper.PostAsync(wcsIpAddrss, station.ToJsonString()).Result; |
| | | content = JsonConvert.DeserializeObject<WebResponseContent>(abc); |
| | | if (content.Data.ObjToInt() > 0) |
| | | //// 获取WCSip地址相关配置 |
| | | //var wcsIpAddrss = GetWCSIpAddress(); |
| | | //if (wcsIpAddrss == null) |
| | | //{ |
| | | // throw new InvalidOperationException("WCS IP 未配置"); |
| | | //} |
| | | |
| | | //var abc = HttpHelper.PostAsync(wcsIpAddrss, station.ToJsonString()).Result; |
| | | //content = JsonConvert.DeserializeObject<WebResponseContent>(abc); |
| | | //var num = content.Data.ObjToInt(); |
| | | |
| | | |
| | | // TODO 判断在途数量 |
| | | var count = BaseDal.QueryData(x => x.TargetAddress == stationManagers[0].Roadway).Count; |
| | | if (count <= 10) |
| | | { |
| | | // 送至包装 |
| | | List<string> strings = stationManagers.Where(x => x.stationType == 0).Select(x => x.Roadway).ToList(); |