Пример #1
0
        public ActionResult ChooseSeat(int movieRoomRelationId, string seat)
        {
            var service = new MovieService();
            var seatPosition = seat.Split('_');
            if (service.ReserveSeat(1, movieRoomRelationId, int.Parse(seatPosition[0]), int.Parse(seatPosition[1])))
            {
                return RedirectToAction("SeatTaken");
            }

            return RedirectToAction("ChooseSeat", new { movieRoomRelationId });
        }
Пример #2
0
 public ActionResult Index()
 {
     var service = new MovieService();
     return View(service.GetMovies(DateTime.Now));
 }
Пример #3
0
 public ActionResult ChooseSeat(int movieRoomRelationId)
 {
     var service = new MovieService();
     return View(service.GetRoomByRelation(movieRoomRelationId));
 }