Пример #1
0
 public IActionResult OnGet(int theaterId)
 {
     Theaters = theaterData.GetById(theaterId);
     if (Theaters == null)
     {
         return(RedirectToPage("./NotFound"));
     }
     return(Page());
 }
Пример #2
0
        public IActionResult OnGet(int?theaterID)
        {
            Performances = htmlHelper.GetEnumSelectList <PerformanceType>();
            if (theaterID.HasValue)
            {
                Theaters = theaterData.GetById(theaterID.Value);
            }
            else
            {
                Theaters = new Theaters();
            }

            if (Theaters == null)
            {
                return(RedirectToPage("./NotFound"));
            }
            return(Page());
        }