public void Initialize() { // Main module _adminScreenInfo = MenuInfo.Create(1, "Workplan", true, false, false, false); _screenFactoryRegistry.RegisterFactory(_adminScreenInfo.ScreenGuid, _forecastScreenFactory); _menuRegistry.RegisterMenuInfo(_adminScreenInfo); // Sub module Registration var submenuForecastRegistration = SubMenuInfo.Create("Registration", typeof(ForecastRegistrationRootView).Name, _adminScreenInfo); submenuForecastRegistration.IsActive = true; _adminScreenInfo.AddSubMenu(submenuForecastRegistration); // Sub module Overview var submenuForecastOverview = SubMenuInfo.Create("Overview", typeof(ForecastOverviewView).Name, _adminScreenInfo); _adminScreenInfo.AddSubMenu(submenuForecastOverview); }
/// <summary> /// Notifies the module that it has be initialized. /// </summary> public void Initialize() { taskAdminScreenInfo = MenuInfo.Create(1, "Overview", true, _appSettings.StartScreenIsWeekOverview, false, true); _screenFactoryRegistry.RegisterFactory(taskAdminScreenInfo.ScreenGuid, new OverviewScreenFactory(_unityContainer)); _menuRegistry.RegisterMenuInfo(taskAdminScreenInfo); // Disabled for H&B //_subMenuDailyOverview = SubMenuInfo.Create("Daily", typeof(DayOverviewScreen.DayOverviewScreen).Name, taskAdminScreenInfo); //_subMenuDailyOverview.IsActive = !_appSettings.StartScreenIsWeekOverview; //taskAdminScreenInfo.AddSubMenu(_subMenuDailyOverview); _subMenuWeekly = SubMenuInfo.Create("Weekly", typeof(WeeklyOverviewScreen.WeeklyOverviewScreen).Name, taskAdminScreenInfo); _subMenuWeekly.IsActive = _appSettings.StartScreenIsWeekOverview; taskAdminScreenInfo.AddSubMenu(_subMenuWeekly); var overview = _unityContainer.Resolve <IOverviewSwitcherService>(); // Disabled for H&B //overview.AttachDailyOverviewSubmenu(_subMenuDailyOverview); overview.AttachWeeklyOverviewSubmenu(_subMenuWeekly); _unityContainer.Resolve <IDialogService>(); }