Skip to content

Commit

Permalink
Booking Feature Commented as API of Booking now needs Captcha and whi…
Browse files Browse the repository at this point in the history
…ch would break the system
  • Loading branch information
sauravsaha committed May 7, 2021
1 parent 57781ed commit 286e73c
Showing 1 changed file with 15 additions and 14 deletions.
29 changes: 15 additions & 14 deletions COWIN/Models/CovidVaccinationCenter.cs
Original file line number Diff line number Diff line change
Expand Up @@ -95,21 +95,22 @@ private void GetAvailableSlots(CovidVaccinationCenters covidVaccinationCenters)
session.Vaccine == _configuration["CoWinAPI:VaccineType"] &&
cvc.FeeType == _configuration["CoWinAPI:VaccineFeeType"] )
{
foreach(var slot in session.Slots)
{
Console.ResetColor();
Console.ForegroundColor = ConsoleColor.Yellow;
Console.WriteLine($"Trying to Book Appointment for CVC: {cvc.Name} - PIN: {cvc.Pincode} - District: {cvc.DistrictName} - Date: {session.Date} - Slot: {slot}");
Console.ResetColor();
var isBookingSuccessful = BookAvailableSlot(session.SessionId, slot);

if (isBookingSuccessful == true)
{
DisplaySlotInfo(cvc, session);
break;
}
// Commented this as currently due to Captcha Requirement in Booking APIs, we are unable to create the Booking Automatically
//foreach(var slot in session.Slots)
//{
// Console.ResetColor();
// Console.ForegroundColor = ConsoleColor.Yellow;
// Console.WriteLine($"Trying to Book Appointment for CVC: {cvc.Name} - PIN: {cvc.Pincode} - District: {cvc.DistrictName} - Date: {session.Date} - Slot: {slot}");
// Console.ResetColor();
// var isBookingSuccessful = BookAvailableSlot(session.SessionId, slot);

// if (isBookingSuccessful == true)
// {
// DisplaySlotInfo(cvc, session);
// break;
// }

}
//}
DisplaySlotInfo(cvc, session);
}
}
Expand Down

0 comments on commit 286e73c

Please sign in to comment.