示例#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));
        }
 public UserReviewsFilterCommand(UserRatingsViewModel userRatingsViewModel, ObservableCollection <FilmReview> filmReviews)
 {
     _userRatingsViewModel = userRatingsViewModel;
     _filmReviews          = filmReviews;
 }