Exemplo n.º 1
0
        //fetches the details of a profile
        public ActionResult Details(int id = 0)
        {
            Account account = GetAccount();
            Profile profile = profileDAL.fetchByAccountID(account.accountID);

            if (profile == null)
            {
                TempData["errorMessage"] = "Sorry. This user does not exist !";
                return(RedirectToAction("Account/Login"));
            }

            DetailsViewModel model = new DetailsViewModel(profile);

            return(View(model));
        }