Exemplo 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));
        }
Exemplo 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));
        }