示例#1
0
        private void MakeFirmaMenu(FirmaSession currentFirmaSession)
        {
            TopLevelLtInfoMenuItems = new List <LtInfoMenuItem>
            {
                BuildAboutMenu(currentFirmaSession),
                BuildProjectsMenu(currentFirmaSession),
                // WARNING: This has been deleted multiple times. We are manually re-adding it. If a conflict occurs here, lets talk - SMG & SLG
                BuildAgreementsMenu(currentFirmaSession),
                //BuildObligationsMenu(currentFirmaSession),
                BuildProgramInfoMenu(currentFirmaSession)
            };

            if (MultiTenantHelpers.DisplayAccomplishmentDashboard() || MultiTenantHelpers.UsesCustomResultsPages(currentFirmaSession))
            {
                TopLevelLtInfoMenuItems.Add(BuildResultsMenu(currentFirmaSession));
            }

            if (MultiTenantHelpers.DisplayReportsLink())
            {
                TopLevelLtInfoMenuItems.Add(BuildReportsMenu(currentFirmaSession));
            }

            TopLevelLtInfoMenuItems.Add(BuildManageMenu(currentFirmaSession));
            TopLevelLtInfoMenuItems.Add(BuildConfigureMenu(currentFirmaSession));

            TopLevelLtInfoMenuItems.ForEach(x => x.ExtraTopLevelMenuCssClasses = new List <string> {
                "navigation-root-item"
            });
            TopLevelLtInfoMenuItems.SelectMany(x => x.ChildMenus).ToList().ForEach(x => x.ExtraTopLevelMenuCssClasses = new List <string> {
                "navigation-dropdown-item"
            });

            HelpMenu = new LtInfoMenuItem("Help");
            HelpMenu.AddMenuItem(LtInfoMenuItem.MakeItem("Request Support",
                                                         ModalDialogFormHelper.ModalDialogFormLink("Request Support", RequestSupportUrl, "Request Support", 800,
                                                                                                   "Submit Request", "Cancel", new List <string>(), null, null).ToString(), "ToolHelp"));
            HelpMenu.AddMenuItem(LtInfoMenuItem.MakeItem(new SitkaRoute <HomeController>(c => c.Training()), currentFirmaSession, "Training", "ToolHelp"));
            HelpMenu.AddMenuItem(LtInfoMenuItem.MakeItem(new SitkaRoute <HomeController>(c => c.InternalSetupNotes()), currentFirmaSession, "Internal Setup Notes", "ToolHelp"));
            HelpMenu.AddMenuItem(LtInfoMenuItem.MakeItem(new SitkaRoute <HomeController>(c => c.ReleaseNotes()), currentFirmaSession, "Release Notes", "ToolHelp"));
            AddCustomPagesToMenu(currentFirmaSession, FirmaMenuItem.Help, HelpMenu, "CustomHelp");
            HelpMenu.AddMenuItem(LtInfoMenuItem.MakeItem("About ProjectFirma",
                                                         @"<a href='http://www.sitkatech.com/products/ProjectFirma/projectfirma-faqs/' target='_blank'>About ProjectFirma <span class='glyphicon glyphicon-new-window'></span></a>", "ExternalHelp"));
        }