public override void OnActionExecuting(ActionExecutingContext filterContext) { if (!RvsPrincipal.IsSuperUser()) { filterContext.Result = new RedirectToRouteResult( new RouteValueDictionary { { "controller", "Home" }, { "action", "Index" } }); } }
public static bool IsSuperUser(this HtmlHelper html) { return(RvsPrincipal.IsSuperUser()); }