Esempio n. 1
0
        public static string Action <T>(UrlHelper urlHelper,
                                        string actionName)
            where T : Controller
        {
            var controllerName = ControllerNameUtility.GetControllerPath(typeof(T).Name);

            return(urlHelper.Action(actionName,
                                    controllerName));
        }
Esempio n. 2
0
        public static string Action <T>(UrlHelper urlHelper,
                                        string actionName,
                                        RouteValueDictionary routeValues,
                                        string protocol)
            where T : Controller
        {
            var controllerName = ControllerNameUtility.GetControllerPath(typeof(T).Name);

            return(urlHelper.Action(actionName,
                                    controllerName,
                                    routeValues,
                                    protocol));
        }