Beispiel #1
0
 internal static void ShowReceiptWithMoney(Casette casette, RentalOptions options)
 {
     Console.WriteLine();
     Console.WriteLine(
         "Rented:\n" +
         $"{casette.Title.Name}, {casette.Title.Year} ({casette.Title.Type}) {options.RentalDays} days {options.Price} Eur");
     Console.WriteLine();
     Pause();
 }
Beispiel #2
0
 internal static bool GetConfirmationForTerms(Casette casette, RentalOptions options)
 {
     Console.WriteLine();
     Console.WriteLine(
         $"You have selected:\n" +
         $"{casette.Title.Name}, {casette.Title.Year} ({options.TitleType}) {options.RentalDays} days ---> {options.Price} Eur");
     Console.WriteLine();
     return(GetConfirmation("Agree to rent? (y/n) ", "y"));
 }
Beispiel #3
0
 internal static bool GetConfirmationForPayingByPoints(RentalOptions options)
 {
     Console.WriteLine();
     Console.WriteLine(
         $"You have {options.PointsAvailable} bonus points accumulated.\n" +
         $"You can pay {options.PriceInPoints} points for this rental.");
     Console.WriteLine();
     return(GetConfirmation("Pay by points? (y/n) ", "y"));
 }
Beispiel #4
0
 internal static void ShowReceiptWithPoints(Casette casette, RentalOptions options, int bonusPointsRemaining)
 {
     Console.WriteLine();
     Console.WriteLine(
         "Rented:\n" +
         $"{casette.Title.Name}, {casette.Title.Year} ({casette.Title.Type}) {options.RentalDays} days (Paid with {options.PriceInPoints} bonus points)\n" +
         $"Remaining bonus points: {bonusPointsRemaining}");
     Console.WriteLine();
     Pause();
 }
Beispiel #5
0
 private void CalculateTerms()
 {
     casette = store.GetCasetteOnShelfByTitle(film.Id);
     options = store.GetRentalOptions(customer.Id, casette.Title.Type, dayCount);
 }