Exemple #1
0
        //
        // GET: /Files/

        public ActionResult Index()
        {
            UserProfile user = _usersRepository.GetUserProfileByName(User.Identity.Name);

            // Check if user already exists
            if (user != null)
            {
                var usersFiles = _filesRepository.GetFilesForUserProfile(user);
                return(View(usersFiles));
            }

            return(RedirectToAction("Index", "Home"));
        }