public static void GetTenderData(Int32 tenderNumber) { RequestResult <TenderData> reqResult = ApsClient.GetTenderData(tenderNumber); if (!reqResult.IsSuccess) { Console.WriteLine("Не удалось получить информацию о состоянии тендера"); return; } TenderData tenderData = reqResult.Data; tenderData.Show(); }
public static TenderData Retrieve(ApsClient apsClient, Int32 tenderNumber) { var requestResult = apsClient.GetTenderData(tenderNumber); if (requestResult.IsSuccess == false) { throw new InvalidOperationException($"Error: {requestResult.ErrorCode} — {requestResult.ErrorString}"); } return(requestResult.Data); }
public static TenderData RetrieveFullData(ApsClient apsClient, Int32 tenderNumber) { var requestResult = apsClient.GetTenderData(tenderNumber); if (requestResult.IsSuccess == false) { throw new InvalidOperationException($"Error: {requestResult.ErrorCode} — {requestResult.ErrorString}"); } TenderData tenderData = requestResult.Data; List <TenderLotItemOffer> offers = apsClient.GetTenderRoundOffers(tenderData); apsClient.GetFilesFromCommertialOffers(tenderData, @"C:\_APS Tender"); return(tenderData); }