Ejemplo n.º 1
0
        private static void SetupScheduleRoutes()
        {
            List <string> entityNamesSchedule = new List <string>(new string[]        {
                "CustomTimeLog", "Schedule", "ScheduleDetail",
                "ScheduleHistory", "ScheduleItem", "ScheduleQuestion", "ScheduleState", "VacationPlan", "ScheduleView"
            });

            foreach (string entity in entityNamesSchedule)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/Scheduling/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/Scheduling/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/Scheduling/{0}/Default.aspx", dataItem.EntityName);
                    }
                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 2
0
        private static void SetupAptitudeRoutes()
        {
            List <string> entityNamesProductivity = new List <string>(new string[]    {
                "Competency", "CompetencyXSkill", "Skill", "SkillLevel", "SkillXPersonXSkillLevel"
            });

            foreach (string entity in entityNamesProductivity)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/Aptitude/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/Aptitude/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/Aptitude/{0}/Default.aspx", dataItem.EntityName);
                    }
                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 3
0
        private static void SetupRiskAndRewardRoutes()
        {
            List <string> entityNamesRiskAndReward = new List <string>(new string[]   {
                "Reward", "Risk"
            });

            foreach (string entity in entityNamesRiskAndReward)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/RiskAndReward/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/RiskAndReward/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        dataItem.RelativeRoute = string.Format("~/BM/RiskAndReward/{0}/Default.aspx", dataItem.EntityName);
                    }
                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 4
0
        private static void SetupClientRoute()
        {
            var oApplicationRouteDataModel = new ApplicationRouteDataModel();

            oApplicationRouteDataModel.EntityName = "Client";

            var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

            foreach (var dataItem in items)
            {
                if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                {
                    dataItem.RelativeRoute = string.Format("~/PMO/{0}/{{action}}.aspx", dataItem.EntityName);
                }
                else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                {
                    dataItem.RelativeRoute = string.Format("~/PMO/{0}/{{action}}.aspx", dataItem.EntityName);
                }
                else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                {
                    dataItem.RelativeRoute = string.Format("~/PMO/{0}/Default.aspx", dataItem.EntityName);
                }

                ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
            }
        }
Ejemplo n.º 5
0
        private static void SetupApplicationDevelopmentRoutes()
        {
            List <string> entityNamesAppDev = new List <string>(new string[]  {
                "AllEntityDetail", "DeveloperRole", "EntityOwner", "FeatureOwnerStatus", "Functionality", "FunctionalityActiveStatus",
                "FunctionalityEntityStatus", "FunctionalityEntityStatusArchive", "FunctionalityHistory", "FunctionalityImage",
                "FunctionalityImageAttribute", "FunctionalityImageInstance", "FunctionalityOwner", "FunctionalityPriority",
                "FunctionalityStatus", "FunctionalityXFunctionalityActiveStatus", "FunctionalityXFunctionalityImage",
                "Module", "ModuleOwner"
            });

            foreach (string entity in entityNamesAppDev)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/ApplicationDevelopment/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/ApplicationDevelopment/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/ApplicationDevelopment/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 6
0
        private static void SetupENRoutes()
        {
            List <string> entityNamesAppDev = new List <string>(new string[]  {
                "NotificationEventType", "NotificationPublisher",
                "NotificationPublisherXEventType", "NotificationRegistrar", "NotificationSubscriber"
            });

            foreach (string entity in entityNamesAppDev)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/EventNotification/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/EventNotification/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/EventNotification/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 7
0
        private static void SetupAuthAndAuthRoutes()
        {
            List <string> entityNamesAuthAndAuth = new List <string>(new string[] {
                "ApplicationOperation", "ApplicationRole", "ApplicationUser",
                "ApplicationUserProfileImage", "ApplicationUserProfileImageMaster", "ApplicationUserTitle"
            });

            foreach (string entity in entityNamesAuthAndAuth)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/AuthenticationAndAuthorization/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/AuthenticationAndAuthorization/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/AuthenticationAndAuthorization/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 8
0
        private static void SetupEMRoutes()
        {
            List <string> entityNamesAuthAndAuth = new List <string>(new string[] {
                "ApplicationMonitoredEvent", "ApplicationMonitoredEventEmail",
                "ApplicationMonitoredEventProcessingState", "ApplicationMonitoredEventSource"
            });

            foreach (string entity in entityNamesAuthAndAuth)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/EventMonitoring/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/EventMonitoring/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/EventMonitoring/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 9
0
        private static void SetupTasksAndWorkflowRoutes()
        {
            List <string> entityNamesAuthAndAuth = new List <string>(new string[] {
                "TaskEntity", "TaskEntityType", "TaskRun", "TaskSchedule", "TaskScheduleType"
            });

            foreach (string entity in entityNamesAuthAndAuth)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/TasksAndWorkflow/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/TasksAndWorkflow/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MS/TasksAndWorkflow/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 10
0
        private static void SetupApplicationManagementRoutes()
        {
            List <string> entityNamesAppMgmt = new List <string>(new string[] {
                "HelpPage", "HelpPageContext"
            });

            foreach (string entity in entityNamesAppMgmt)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/ApplicationManagement/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/ApplicationManagement/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/MA/ApplicationManagement/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 11
0
        private static void SetupConfigurationRoutes()
        {
            var entityNames = new List <string>(new string[]     {
                "Application", "ApplicationMode", "ApplicationModeXFieldConfigurationMode", "ApplicationRoute", "ApplicationRouteParameter",
                "DateRangeTitle", "FieldConfiguration", "FieldConfigurationMode", "FieldConfigurationAccessMode",
                "FieldConfigurationModeCategory", "FieldConfigurationModeCategoryXFCMode", "FieldConfigurationModeXApplicationRole",
                "FieldConfigurationModeXApplicationRole", "Language", "Menu", "MenuCategory", "MenuCategoryXMenu",
                "SystemForeignRelationship", "SystemForeignRelationshipDatabase", "SystemForeignRelationshipType",
                "TabChildStructure", "TabParentStructure", "Theme", "ThemeCategory", "ThemeDetail", "ThemeKey",
                "UserPreference", "UserPreferenceCategory", "UserPreferenceKey", "UserPreferenceDataType", "UserPreferenceSelectedItem"
            });

            foreach (string entity in entityNames)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        dataItem.RelativeRoute = string.Format("~/Configuration/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        dataItem.RelativeRoute = string.Format("~/Configuration/{0}/{{action}}.aspx", dataItem.EntityName);
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        dataItem.RelativeRoute = string.Format("~/Configuration/{0}/Default.aspx", dataItem.EntityName);
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                    //break;
                }
                //break;
            }
        }
Ejemplo n.º 12
0
        private static void SetupRARoutes()
        {
            List <string> entityNamesRA = new List <string>(new string[]      {
                "Feature", "FeatureGroup", "FeatureGroupXFeature", "FeatureRule", "FeatureRuleCategory", "FeatureRuleStatus",
                "FeatureXFeatureRule", "Need", "NeedXFeature", "ProjectUseCaseStatus", "ProjectUseCaseStatusArchieve",
                "ProjectXNeed", "ProjectXUseCase", "UseCase", "UseCaseActor", "UseCaseActorXUseCase",
                "UseCasePackage", "UseCasePackageXUseCase", "UseCaseRelationship", "UseCaseStep",
                "UseCaseWorkFlowCategory", "UseCaseXUseCaseStep"
            });

            foreach (string entity in entityNamesRA)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());
                switch (entity)
                {
                case "FeatureGroup":
                case "FeatureGroupXFeature":
                case "FeatureRule":
                case "FeatureRuleCategory":
                case "FeatureRuleStatus":
                case "FeatureXFeatureRule":
                    route1 = "~/BM/RequirementAnalysis/Feature/";
                    break;
                }

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/RequirementAnalysis/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/RequirementAnalysis/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/RequirementAnalysis/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 13
0
        private static void SetupPMORoutes()
        {
            List <string> entityNamesPMO = new List <string>(new string[]     {
                "Client", "ClientXProject", "Layer", "Milestone",
                "MilestoneFeatureState", "MilestoneXFeature", "MilestoneXFeatureArchive",
                "Project", "ProjectTimeLine",
                "ProjectPortfolio", "ProjectPortfolioGroup", "ProjectPortfolioGroupXProjectPortfolio"
            });

            foreach (string entity in entityNamesPMO)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());
                switch (entity)
                {
                case "Client":
                case "ClientXProject":
                case "Layer":
                case "Milestone":
                    route1 = "~/BM/PMO/";
                    break;

                case "MilestoneFeatureState":
                case "MilestoneXFeature":
                case "MilestoneXFeatureArchive":
                    route1 = "~/BM/PMO/Milestone/";
                    break;

                case "Project":
                case "ProjectTimeLine":
                    route1 = "~/BM/PMO/ProjectManagement/";
                    break;

                case "ProjectPortfolio":
                case "ProjectPortfolioGroup":
                case "ProjectPortfolioGroupXProjectPortfolio":
                    route1 = "~/BM/PMO/ProjectManagement/Project/";
                    break;
                }

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/PMO/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/PMO/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/PMO/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 14
0
        protected override DataTable GetData()
        {
            var dt = ApplicationRouteDataManager.Search(oSearchFilter.SearchParameters, SessionVariables.RequestProfile);

            return(dt);
        }
Ejemplo n.º 15
0
        private static void SetupQuestionRoutes()
        {
            List <string> entityNamesPMO = new List <string>(new string[]     {
                "Question", "QuestionCategory"
            });

            foreach (string entity in entityNamesPMO)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());
                switch (entity)
                {
                case "QuestionCategory":
                    route1 = "~/BM/Question/";
                    break;
                }

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 16
0
        private static void SetupWBSRoutes()
        {
            var entityNamesWBS = new List <string>(new string[]      {});

            foreach (string entity in entityNamesWBS)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());
                switch (entity)
                {
                case "DeliverableArtifactStatus":
                    route1 = "~/WBS/DeliverableArtifact/";
                    break;
                    //default:
                    //	route1 = "~/WBS/";
                    //	break;
                }

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/WBS/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/WBS/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/WBS/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 17
0
        private static void SetupWBSRoutes()
        {
            List <string> entityNamesWBS = new List <string>(new string[]     {
                "Activity", "ActivityState", "ActivityXDeliverableArtifact",
                "DeliverableArtifact", "DeliverableArtifactStatus", "FeatureXTask", "Task", "TaskAlgorithm", "TaskAlgorithmItem", "TaskFormulation",
                "TaskNote", "TaskPackage", "TaskPackageXOwnerXTask", "TaskPersonMapping", "TaskPriorityType",
                "TaskPriorityXApplicationUser", "TaskTiskRewardRankingPerson", "TaskRole", "TaskStatusType", "TaskType", "TaskXActivityInstance",
                "TaskXCompetency", "TaskXDeliverableArtifact"
            });

            foreach (string entity in entityNamesWBS)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());
                switch (entity)
                {
                case "DeliverableArtifactStatus":
                    route1 = "~/BM/WBS/DeliverableArtifact/";
                    break;
                    //default:
                    //	route1 = "~/WBS/";
                    //	break;
                }

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/WBS/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/WBS/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/WBS/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 18
0
        private static void SetupTCMRoutes()
        {
            List <string> entityNamesTCM = new List <string>(new string[] {
                "TestCase", "TestCaseOwner", "TestCasePriority", "TestCaseStatus",
                "TestRun", "TestSuite", "TestSuiteXTestCase",
                "TestSuiteXTestCaseArchive"
            });

            foreach (string entity in entityNamesTCM)
            {
                var oApplicationRouteDataModel = new ApplicationRouteDataModel();

                oApplicationRouteDataModel.EntityName = entity;
                var route1 = string.Empty;

                var items = ApplicationRouteDataManager.GetEntityDetails(oApplicationRouteDataModel, Global.GetStartupProfile());
                switch (entity)
                {
                case "TestCase":
                case "TestCaseOwner":
                case "TestCasePriority":
                case "TestCaseStatus":
                case "TestRun":
                case "TestSuite":
                case "TestSuiteXTestCase":
                case "TestSuiteXTestCaseArchive":
                    route1 = "~/BM/TCM/";
                    break;
                }

                foreach (var dataItem in items)
                {
                    if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRoute"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/TCM/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSuperKey"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/TCM/{0}/{{action}}.aspx", dataItem.EntityName);
                        }
                    }
                    else if (dataItem.RouteName.Equals(dataItem.EntityName + "EntityRouteSearch"))
                    {
                        if (route1 != string.Empty)
                        {
                            dataItem.RelativeRoute = string.Format(route1 + "{0}/Default.aspx", dataItem.EntityName);
                        }
                        else
                        {
                            dataItem.RelativeRoute = string.Format("~/BM/TCM/{0}/Default.aspx", dataItem.EntityName);
                        }
                    }

                    ApplicationRouteDataManager.Update(dataItem, Global.GetStartupProfile());
                }
            }
        }
Ejemplo n.º 19
0
        public static void RegisterRoutes(RouteCollection routes)
        {
            Log4Net.LogInfo("RegisterRoutes Start");

            routes.Ignore("{resource}.axd");
            routes.IgnoreRoute("{resource}.axd/{*pathInfo}");

            // fixes issues regarding Web Service call from javascript (scripts -> library -> kendo.js)
            routes.Add(new Route("API/{resource}.asmx/{*pathInfo}", new StopRoutingHandler()));

            RouteConfig.RegisterRoutes(RouteTable.Routes);

            // 1-1 mapping of home pages for each .net application
            routes.MapPageRoute("PMTHomeRoute",
                                "PMT/PMT/Home",
                                "~/BM/PMO/Default.aspx",
                                true);

            routes.MapPageRoute("TEHomeRoute",
                                "TE/TE/Home",
                                "~/BM/Scheduling/Default.aspx",
                                true);

            routes.MapPageRoute("PDTMGMDEVTHomeRoute",
                                "PDTMGMDEVT/PDTMGMDEVT/Home",
                                "~/BM/RequirementAnalysis/Default.aspx",
                                true);

            routes.MapPageRoute("PrototypeHomeRoute",
                                "Prototype/Prototype/Home",
                                "~/Prototype/Default.aspx",
                                true);

            routes.MapPageRoute("SAHomeRoute",
                                "SA/SA/Home",
                                "~/Shared/SA/Default.aspx",
                                true);

            //routes.MapPageRoute("LegalHomeRoute",
            //	"Legal/Home",
            //	"~/BM/Legal/Default.aspx",
            //	true);

            var systemRequestProfile = GetStartupProfile();

            var dtRoutes     = ApplicationRouteDataManager.GetList(systemRequestProfile);
            var dtParameters = ApplicationRouteParameterDataManager.GetList(systemRequestProfile);

            // add routes which maps default pages to search first
            var searchRouteRows = dtRoutes.Select("RouteName LIKE '%EntityRouteSearch'");

            if (searchRouteRows.Length > 0)
            {
                foreach (DataRow dr in searchRouteRows)
                {
                    var proposedRoute = "{applicationCode}/{applicationModule}/" + Convert.ToString(dr[ApplicationRouteDataModel.DataColumns.ProposedRoute]);
                    var relativeRoute = Convert.ToString(dr[ApplicationRouteDataModel.DataColumns.RelativeRoute]);
                    var routeName     = Convert.ToString(dr[ApplicationRouteDataModel.DataColumns.RouteName]);

                    // MapPageRoute provides a way to define routes for Web Forms applications.
                    routes.MapPageRoute(routeName, proposedRoute, relativeRoute, true);
                }
            }

            // add other routes
            searchRouteRows = dtRoutes.Select("RouteName NOT LIKE '%EntityRouteSearch'");
            if (searchRouteRows.Length > 0)
            {
                foreach (DataRow dr in searchRouteRows)
                {
                    var proposedRoute = "{applicationCode}/{applicationModule}/" + Convert.ToString(dr[ApplicationRouteDataModel.DataColumns.ProposedRoute]);
                    var relativeRoute = Convert.ToString(dr[ApplicationRouteDataModel.DataColumns.RelativeRoute]);
                    var appRouteId    = Convert.ToInt32(dr[ApplicationRouteDataModel.DataColumns.ApplicationRouteId]);
                    var routeName     = Convert.ToString(dr[ApplicationRouteDataModel.DataColumns.RouteName]);

                    var routeParamList  = new RouteValueDictionary();
                    var routeParameters = dtParameters.Select(ApplicationRouteParameterDataModel.DataColumns.ApplicationRouteId + " = " + appRouteId);

                    if (routeParameters.Length > 0)
                    {
                        foreach (DataRow drParam in routeParameters)
                        {
                            var key   = drParam[ApplicationRouteParameterDataModel.DataColumns.ParameterName];
                            var value = drParam[ApplicationRouteParameterDataModel.DataColumns.ParameterValue];

                            routeParamList.Add(key.ToString(), value.ToString());
                        }

                        routeParamList.Add("applicationCode", "PMT");
                        //routeParamList.Add("applicationModule", "AA");
                    }

                    // MapPageRoute provides a way to define routes for Web Forms applications.
                    routes.MapPageRoute(routeName, proposedRoute, relativeRoute, true, routeParamList);
                }
            }

            //routes.MapRoute(
            //	name: "Default",
            //	url: "{controller}/{action}/{id}",
            //	defaults: new { controller = "Home", action = "Index", id = UrlParameter.Optional },
            //	namespaces: new[] { "Areas.Controllers" }
            //);

            //// Single Page Routing Example of a test page
            //routes.MapPageRoute("testRoute",
            //	"Test/TestPaging",
            //	"~/Shared/ApplicationManagement/Development/TestPaging/Test.aspx",
            //	true);

            //routes.MapPageRoute("testAng",
            //	"Test/Home",
            //	"~/Test/Home/Index.cshtml",
            //	false);

            //routes.MapPageRoute("TestPage1",
            //	"Page1",
            //	"~/Areas/AngularTest/app/app.js",
            //	false);

            //routes.MapPageRoute("d", "abcd", "~/Areas/AngularTest/app/core/views/nav.html", false);

            Log4Net.LogInfo("RegisterRoutes End");
        }