Beispiel #1
0
 public IActionResult CreateNewRental([FromForm] NewRentalDto newRental)
 {
     if (_rentals.CreateRental(newRental) == RentalResult.NotAvailable)
     {
         return(BadRequest("Movie is not available."));
     }
     else
     {
         return(Ok());
     }
 }