Example #1
0
        public ActionResult WatchList()
        {
            User user = _userService.GetUsersByUserName(User.Identity.GetUserName());

            moviesSeriesList = new List <MoviesSeries>();
            List <MoviesSeriesWatchList> moviesSeriesWatchList = _moviesSeriesWatchListService.GetMoviesSeriesWatchListByWatchList(user.UserID);

            foreach (var item in moviesSeriesWatchList)
            {
                moviesSeriesList.Add(_moviesSeriesService.GetMoviesSeriesById(item.MoviesSeriesID));
            }
            ViewBag.WatchList = moviesSeriesList;
            return(View(user));
        }
        public ActionResult Details(int?id)
        {
            if (id == null)
            {
                return(new HttpStatusCodeResult(HttpStatusCode.BadRequest));
            }
            MoviesSeries moviesSeries = _moviesSeriesService.GetMoviesSeriesById(id);

            if (moviesSeries == null)
            {
                return(HttpNotFound());
            }
            return(View(moviesSeries));
        }