Ejemplo n.º 1
0
        // Dropdown

        public static ComponentBuilder <MvcBootstrapConfig <TModel>, DropdownLink> DropdownLink <TComponent, TModel>(
            this BootstrapHelper <MvcBootstrapConfig <TModel>, TComponent> helper, string text, string actionName, string controllerName, object routeValues = null)
            where TComponent : Component, ICanCreate <DropdownLink>
        {
            return(new ComponentBuilder <MvcBootstrapConfig <TModel>, DropdownLink>(helper.GetConfig(), helper.DropdownLink(text, null).GetComponent())
                   .SetAction(actionName, controllerName, routeValues)
                   .SetText(text));
        }
        // Dropdown

        public static ComponentBuilder <MvcBootstrapConfig <TModel>, DropdownLink> DropdownLink <TComponent, TModel>(
            this BootstrapHelper <MvcBootstrapConfig <TModel>, TComponent> helper, string text, ActionResult result)
            where TComponent : Component, ICanCreate <DropdownLink>
        {
            return(new ComponentBuilder <MvcBootstrapConfig <TModel>, DropdownLink>(helper.GetConfig(), helper.DropdownLink(text, (string)null).GetComponent())
                   .SetLinkAction(result)
                   .SetText(text));
        }