| | |
| | | { |
| | | //Data zzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "左轴é¢å¹³åå¼").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | //if (null != zzjAVG) queryZCInfo.zzjAVG = decimal.Parse(zzjAVG.value).ToString("N3"); |
| | | Data zzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "左轴é¢ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | //Data zzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "左轴é¢ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | //if (null != zzjAVG) queryZCInfo.zzjAVG = decimal.Parse(zzjAVG.value).ToString("N3"); |
| | | |
| | | //Data yzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "å³è½´é¢ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | //if (null != yzjAVG) queryZCInfo.yzjAVG = decimal.Parse(yzjAVG.value).ToString("N3"); |
| | | |
| | | //Data zfcbAVG = xmlEntity.Datas.Data.Where(r => r.name == "å·¦é²å°æ¿åº§ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | //if (null != zfcbAVG) queryZCInfo.zfcbAVG = decimal.Parse(zfcbAVG.value).ToString("N3"); |
| | | |
| | | //Data yfcbAVG = xmlEntity.Datas.Data.Where(r => r.name == "å³é²å°æ¿åº§ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | //if (null != yfcbAVG) queryZCInfo.yfcbAVG = decimal.Parse(yfcbAVG.value).ToString("N3"); |
| | | |
| | | |
| | | Data zzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "è½´å·ç«¯è½´é¢ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | if (null != zzjAVG) queryZCInfo.zzjAVG = decimal.Parse(zzjAVG.value).ToString("N3"); |
| | | |
| | | Data yzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "å³è½´é¢ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | Data yzjAVG = xmlEntity.Datas.Data.Where(r => r.name == "éè½´å·ç«¯è½´é¢ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | if (null != yzjAVG) queryZCInfo.yzjAVG = decimal.Parse(yzjAVG.value).ToString("N3"); |
| | | |
| | | Data zfcbAVG = xmlEntity.Datas.Data.Where(r => r.name == "å·¦é²å°æ¿åº§ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | Data zfcbAVG = xmlEntity.Datas.Data.Where(r => r.name == "è½´å·ç«¯é²å°æ¿åº§ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | if (null != zfcbAVG) queryZCInfo.zfcbAVG = decimal.Parse(zfcbAVG.value).ToString("N3"); |
| | | |
| | | Data yfcbAVG = xmlEntity.Datas.Data.Where(r => r.name == "å³é²å°æ¿åº§ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | Data yfcbAVG = xmlEntity.Datas.Data.Where(r => r.name == "éè½´å·ç«¯é²å°æ¿åº§ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | | if (null != yfcbAVG) queryZCInfo.yfcbAVG = decimal.Parse(yfcbAVG.value).ToString("N3"); |
| | | |
| | | //Data zydAVG = xmlEntity.Datas.Data.Where(r => r.name == "左油档ç´å¾").OrderByDescending(r => r.time).FirstOrDefault(); |
| | |
| | | WebResponseContent content = new WebResponseContent(); |
| | | try |
| | | { |
| | | EndpointAddress address = new EndpointAddress("http://172.21.1.117/barcode/Webservice/WebService_ZY/Service_EQP.asmx"); |
| | | //EndpointAddress address = new EndpointAddress("http://172.21.1.117/barcode/Webservice/WebService_ZY/Service_EQP.asmx"); |
| | | //EndpointAddress address = new EndpointAddress(" http://172.21.1.117/barcode/Webservice/WebService_ZY/WebServiceZY.asmx"); |
| | | EndpointAddress address = new EndpointAddress(POSTURL); |
| | | ErpWebService.Service_EQPSoapClient client = new ErpWebService.Service_EQPSoapClient(new BasicHttpBinding(), address); |
| | | Task<ErpWebService.WheelsetMatchResponse> res = client.WheelsetMatchAsync("", "", ""); |
| | | string resultString = res.Result.Body.WheelsetMatchResult; |
| | |
| | | } |
| | | return content; |
| | | } |
| | | |
| | | |
| | | public WebResponseContent UploadMES2(SaveModel saveModel) |
| | | { |
| | | WebResponseContent content = new WebResponseContent(); |
| | | try |
| | | { |
| | | foreach (var item in saveModel.DelKeys) |
| | | { |
| | | string resultString = string.Empty; |
| | | string recordData = string.Empty; |
| | | try |
| | | { |
| | | dt_selectionRecord selects = dt_selectionRecordRepository.Instance.FindFirst(r => r.record_id == Guid.Parse(item.ToString())); |
| | | string json = JsonConvert.SerializeObject(selects, Newtonsoft.Json.Formatting.Indented); |
| | | if (null == selects) |
| | | return content.Error("æªæ¾å°éé
è®°å½."); |
| | | recordData = json; |
| | | EndpointAddress address = new EndpointAddress(ToMesService.POSTURL); |
| | | ErpWebService.Service_EQPSoapClient client = new ErpWebService.Service_EQPSoapClient(new BasicHttpBinding(), address); |
| | | Task<ErpWebService.ReportToSCEResponse> res = client.ReportToSCEAsync(selects.record_materielNumber, json); |
| | | // resultString = res.Result.Body.ReportToSCEResult; |
| | | } |
| | | catch |
| | | { |
| | | |
| | | } |
| | | finally |
| | | { |
| | | LogRecord.WriteLog((int)LogEnum.Mes, $"{UserContext.Current.UserTrueName}ä¸ä¼ MESåæ°:{recordData},ç»æï¼{resultString}"); |
| | | } |
| | | } |
| | | content.OK(); |
| | | } |
| | | catch (Exception ex) |
| | | { |
| | | content.Error("ä¸ä¼ 失败:" + ex.Message); |
| | | } |
| | | finally |
| | | { |
| | | |
| | | } |
| | | return content; |
| | | } |
| | | } |
| | | public class MeasureInfo |
| | | { |