Exemplo n.º 1
0
        public ViewResult Ratings(string Slug)
        {
            var user    = _userManager.Users.Where(u => u.Slug == Slug).FirstOrDefault();
            var ratings = _context.UserRatings.Include(u => u.FilmItem).Where(u => u.ApplicationUserId == user.Id).OrderByDescending(x => x.CreatedAt).ToList();

            UserRatingsViewModel userRatingsViewModel = new UserRatingsViewModel
            {
                Ratings = ratings,
                User    = user
            };

            return(View(userRatingsViewModel));
        }
Exemplo n.º 2
0
 public UserReviewsFilterCommand(UserRatingsViewModel userRatingsViewModel, ObservableCollection <FilmReview> filmReviews)
 {
     _userRatingsViewModel = userRatingsViewModel;
     _filmReviews          = filmReviews;
 }