예제 #1
0
        /// <summary>
        /// Registers actions to render user menus in widget zones.
        /// </summary>
        private void ProcessUserMenus()
        {
            var menusInfo = _menuStorage.GetUserMenuInfos();

            foreach (var info in menusInfo)
            {
                _widgetProvider.RegisterAction(
                    info.WidgetZones,
                    "Menu",
                    "Menu",
                    new { area = "", name = info.SystemName, template = info.Template },
                    info.DisplayOrder);
            }
        }
예제 #2
0
 public static void RegisterAction(this IWidgetProvider provider, Regex widgetZoneExpression, string actionName, string controllerName, object routeValues, int order = 0)
 {
     provider.RegisterAction(widgetZoneExpression, actionName, controllerName, new RouteValueDictionary(routeValues), order);
 }
예제 #3
0
 public static void RegisterAction(this IWidgetProvider provider, string widgetZone, string actionName, string controllerName, RouteValueDictionary routeValues, int order = 0)
 {
     provider.RegisterAction(new[] { widgetZone }, actionName, controllerName, routeValues, order);
 }