public IActionResult Get(int bookingId) { try { return(Ok(iBooking.GetBookingById(bookingId))); } catch (Exception ex) { return(StatusCode(500, ex.Message)); } }
public IActionResult OnGet(Guid id) { Makina = _makinaServices.GetMakinat().Select(x => new SelectListItem { Text = x.MakinaEmer, Value = x.MakinaEmer }) .ToList(); Booking = _services.GetBookingById(id); if (Booking == null) { return(NotFound()); } return(Page()); }