Ejemplo n.º 1
0
        protected override void OnActionExecuted(ActionExecutedContext filterContext)
        {
            base.OnActionExecuted(filterContext);

            if (User.Identity.IsAuthenticated)
            {
                var UserId = int.Parse(User.Identity.Name);

                var userDetails = UserMethod.GetUser(UserId);
                ViewBag.UserName = userDetails.Name;
            }
        }