Example #1
0
        /// <summary>
        /// 以参数方式加载
        /// </summary>
        /// <param name="_xmlparam"></param>
        public void Load(FrmMenuGroup _menuGroup, string _xmlparam)
        {
            if (application != null && application.MainRibbon != null)
            {
                //添加一个主菜单
                IMenuService menuService = (IMenuService)application.GetService(typeof(IMenuService));
                if (menuService != null)
                {
                    //全局定义
                    MenuCommandDefine _md       = new MenuCommandDefine("GlobalDefine", "全局定义", this as IMenuCommand, null);
                    FrmMenuItem       _menuItem = new FrmMenuItem("全局定义", "GlobalDefine",
                                                                  global::SinoSZMetaDataManager.Properties.Resources.g1, 80, _md);
                    menuService.AddMenuItem(_menuGroup, _menuItem);


                    //节点定义
                    _md       = new MenuCommandDefine("NodeDefine", "节点定义", this as IMenuCommand, null);
                    _menuItem = new FrmMenuItem("节点定义", "NodeDefine", global::SinoSZMetaDataManager.Properties.Resources.g2, 80, _md);
                    menuService.AddMenuItem(_menuGroup, _menuItem);

                    //指标定义
                    _md       = new MenuCommandDefine("GuideLineDefine", "指标定义", this as IMenuCommand, null);
                    _menuItem = new FrmMenuItem("指标定义", "GuideLineDefine", global::SinoSZMetaDataManager.Properties.Resources.g25, 80, _md);
                    menuService.AddMenuItem(_menuGroup, _menuItem);
                }
            }
        }
Example #2
0
 public void SuperLoad()
 {
     if (application != null && application.MainRibbon != null)
     {
         //添加一个主菜单
         IMenuService menuService = (IMenuService)application.GetService(typeof(IMenuService));
         if (menuService != null)
         {
             FrmMenuPage _menuPage = new FrmMenuPage("MetaDataManagerPage", "元数据管理");
             menuService.AddMainMenuPage(_menuPage);
             FrmMenuGroup _menuGroup = new FrmMenuGroup("MetaDataManager", "元数据定义");
             menuService.AddMenuGroup(_menuPage, _menuGroup);
             //全局定义
             MenuCommandDefine _md       = new MenuCommandDefine("GlobalDefine", "全局定义", this as IMenuCommand, null);
             FrmMenuItem       _menuItem = new FrmMenuItem("全局定义", "GlobalDefine",
                                                           global::SinoSZMetaDataManager.Properties.Resources.g1, 80, _md);
             menuService.AddMenuItem(_menuPage, _menuGroup, _menuItem);
             //节点定义
             _md       = new MenuCommandDefine("NodeDefine", "节点定义", this as IMenuCommand, null);
             _menuItem = new FrmMenuItem("节点定义", "NodeDefine", global::SinoSZMetaDataManager.Properties.Resources.g2, 80, _md);
             menuService.AddMenuItem(_menuPage, _menuGroup, _menuItem);
             //指标定义
             _md       = new MenuCommandDefine("GuideLineDefine", "指标定义", this as IMenuCommand, null);
             _menuItem = new FrmMenuItem("指标定义", "GuideLineDefine", global::SinoSZMetaDataManager.Properties.Resources.g3, 80, _md);
             menuService.AddMenuItem(_menuPage, _menuGroup, _menuItem);
         }
     }
 }
Example #3
0
        public FrmMenuItem GetMenuItem(string _commandName, string _displayTitle, string _param)
        {
            MenuCommandDefine _md;
            FrmMenuItem       _menuItem = null;

            switch (_commandName)
            {
            case "GlobalDefine":
                _md       = new MenuCommandDefine("GlobalDefine", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GlobalDefine",
                                            global::SinoSZMetaDataManager.Properties.Resources.g1, 80, _md);
                break;

            case "NodeDefine":
                _md       = new MenuCommandDefine("NodeDefine", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "NodeDefine", global::SinoSZMetaDataManager.Properties.Resources.g2, 80, _md);
                break;

            case "GuideLineDefine":
                _md       = new MenuCommandDefine("GuideLineDefine", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GuideLineDefine", global::SinoSZMetaDataManager.Properties.Resources.g25, 80, _md);
                break;

            case "QueryModelEditor":
                _md       = new MenuCommandDefine("QueryModelEditor", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "QueryModelEditor", global::SinoSZMetaDataManager.Properties.Resources.g25, 80, _md);
                break;
            }
            return(_menuItem);
        }
Example #4
0
 private void ShowNodeData(TreeListNode _tn)
 {
     if (_tn.Tag is FrmMenuItem)
     {
         FrmMenuItem _fmi = _tn.Tag as FrmMenuItem;
         if (!_fmi.Equals(CurrentMenuItem))
         {
             if (_fmi.MenuCommand != null)
             {
                 MenuCommandDefine _mcd = _fmi.MenuCommand;
                 CurrentMenuItem = _fmi;
                 UC_PortalShow _up = new UC_PortalShow(_mcd.CommandParam as string, this.Application, false);
                 CurrentPortalItem = _up;
                 _up.Dock          = DockStyle.Fill;
                 this.splitContainerControl1.Panel2.Controls.Clear();
                 this.splitContainerControl1.Panel2.Controls.Add(_up);
             }
             RaiseMenuChanged();
         }
     }
 }
        /// <summary>
        /// 通过用户名取菜单
        /// </summary>
        /// <param name="_commandName"></param>
        /// <param name="_displayTitle"></param>
        /// <param name="_param"></param>
        /// <returns></returns>
        public FrmMenuItem GetMenuItem(string _commandName, string _displayTitle, string _param)
        {
            MenuCommandDefine _md;
            FrmMenuItem       _menuItem = null;

            switch (_commandName)
            {
            case "RoleManager":      //角色管理
                _md       = new MenuCommandDefine("RoleManager", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "RelationQuery",
                                            global::SinoSZClientUser.Properties.Resources.e1, 80, _md);
                break;

            case "PostManager":     //岗位管理
                _md       = new MenuCommandDefine("PostManager", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "RelationQuery",
                                            global::SinoSZClientUser.Properties.Resources.e4, 80, _md);
                break;

            case "UserManager":     //用户管理
                _md       = new MenuCommandDefine("UserManager", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "RelationQuery",
                                            global::SinoSZClientUser.Properties.Resources.e10, 80, _md);
                break;

            case "UserMobileManager":
                _md       = new MenuCommandDefine("UserMobileManager", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "UserMobileManager",
                                            global::SinoSZClientUser.Properties.Resources.e20, 80, _md);
                break;

            case "UserMappingCUPAA":
                _md       = new MenuCommandDefine("UserMappingCUPAA", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "UserMappingCUPAA",
                                            global::SinoSZClientUser.Properties.Resources.e4, 80, _md);
                break;
            }
            return(_menuItem);
        }
Example #6
0
        /// <summary>
        /// 通过用户名取菜单
        /// </summary>
        /// <param name="_commandName"></param>
        /// <param name="_displayTitle"></param>
        /// <param name="_param"></param>
        /// <returns></returns>
        public FrmMenuItem GetMenuItem(string _commandName, string _displayTitle, string _param)
        {
            MenuCommandDefine _md;
            FrmMenuItem       _menuItem = null;

            switch (_commandName)
            {
            case "CreateReport":      //报表生成
                _md       = new MenuCommandDefine("CreateReport", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "CreateReport",
                                            global::SinoSZClientReport.Properties.Resources.d2, 80, _md);
                break;

            case "BrowseReport":     //报表浏览
                _md       = new MenuCommandDefine("BrowseReport", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "BrowseReport",
                                            global::SinoSZClientReport.Properties.Resources.d3, 80, _md);
                break;

            case "ReportGuideLineQuery":     //报表指标查询
                _md       = new MenuCommandDefine("ReportGuideLineQuery", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "ReportGuideLineQuery",
                                            global::SinoSZClientReport.Properties.Resources.d11, 80, _md);
                break;

            case "DataCheck":     //数据审核
                _md       = new MenuCommandDefine("DataCheck", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "DataCheck",
                                            global::SinoSZClientReport.Properties.Resources.b15, 80, _md);
                break;

            case "DataCheckBoard":     //审核公告
                _md       = new MenuCommandDefine("DataCheckBoard", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "DataCheckBoard",
                                            global::SinoSZClientReport.Properties.Resources.x2, 80, _md);
                break;
            }
            return(_menuItem);
        }
Example #7
0
        public FrmMenuItem GetMenuItem(string _commandName, string _displayTitle, string _param)
        {
            MenuCommandDefine _md;
            FrmMenuItem       _menuItem = null;

            switch (_commandName)
            {
            case "QueryTaskList":
                _md       = new MenuCommandDefine("QueryTaskList", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "QueryTaskList",
                                            global::SinoSZMetaDataQuery.Properties.Resources.x2, 80, _md);
                break;

            case "RelationQuery":
                _md       = new MenuCommandDefine("RelationQuery", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "RelationQuery",
                                            global::SinoSZMetaDataQuery.Properties.Resources.x2, 80, _md);
                break;

            case "FixQuery":
                _md       = new MenuCommandDefine("FixQuery", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "FixQuery",
                                            global::SinoSZMetaDataQuery.Properties.Resources.x2, 80, _md);
                break;

            case "RelationQueryTask":
                _md       = new MenuCommandDefine("RelationQueryTask", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "RelationQueryTask",
                                            global::SinoSZMetaDataQuery.Properties.Resources.x2, 80, _md);
                break;

            case "DataCompare":
                _md       = new MenuCommandDefine("DataCompare", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "DataCompare",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b2, 80, _md);
                break;

            case "DataSearch":
                _md       = new MenuCommandDefine("DataSearch", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "DataSearch",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b, 80, _md);
                break;

            case "GuideLineQuery":
                _md       = new MenuCommandDefine("GuideLineQuery", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GuideLineQuery",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "SingleGuideLineQuery":
                _md       = new MenuCommandDefine("SingleGuideLineQuery", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "SingleGuideLineQuery",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "GuideLineQueryEx":
                _md       = new MenuCommandDefine("GuideLineQueryEx", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GuideLineQueryEx",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "GuideLineShow":
                _md       = new MenuCommandDefine("GuideLineShow", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GuideLineShow",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "GuideLineGroupShow":
                _md       = new MenuCommandDefine("GuideLineGroupShow", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GuideLineGroupShow",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "GuideLineGroupShow2":
                _md       = new MenuCommandDefine("GuideLineGroupShow2", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GuideLineGroupShow2",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "PortalShow":
                _md       = new MenuCommandDefine("PortalShow", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "PortalShow",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "TreeComboPortalShow":
                _md       = new MenuCommandDefine("TreeComboPortalShow", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "TreeComboPortalShow",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "AlertMonitor":
                _md       = new MenuCommandDefine("AlertMonitor", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "AlertMonitor",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;

            case "ParameterSetting":
                _md       = new MenuCommandDefine("ParameterSetting", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "ParameterSetting",
                                            global::SinoSZMetaDataQuery.Properties.Resources.b28, 80, _md);
                break;
            }
            return(_menuItem);
        }
Example #8
0
        /// <summary>
        /// 通过用户名取菜单
        /// </summary>
        /// <param name="_commandName"></param>
        /// <param name="_displayTitle"></param>
        /// <param name="_param"></param>
        /// <returns></returns>
        public FrmMenuItem GetMenuItem(string _commandName, string _displayTitle, string _param)
        {
            MenuCommandDefine _md;
            FrmMenuItem       _menuItem = null;

            switch (_commandName)
            {
            case "IISRecycle":
                _md       = new MenuCommandDefine("IISRecycle", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "IISRecycle",
                                            global::SinoSZClientSysManager.Properties.Resources.e15, 80, _md);
                break;

            case "WinServiceWatch":
                _md       = new MenuCommandDefine("WinServiceWatch", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "WinServiceWatch",
                                            global::SinoSZClientSysManager.Properties.Resources.e15, 80, _md);
                break;

            case "OrganizeExtInfo":
                _md       = new MenuCommandDefine("OrganizeExtInfo", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "OrganizeExtInfo",
                                            global::SinoSZClientSysManager.Properties.Resources.e17, 80, _md);
                break;

            case "SystemLog":      //角色管理
                _md       = new MenuCommandDefine("SystemLog", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "SystemLog",
                                            global::SinoSZClientSysManager.Properties.Resources.e17, 80, _md);
                break;

            case "UserLog":     //岗位管理
                _md       = new MenuCommandDefine("UserLog", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "UserLog",
                                            global::SinoSZClientSysManager.Properties.Resources.e18, 80, _md);
                break;

            case "QueryLog":     //查询日志
                _md       = new MenuCommandDefine("QueryLog", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "QueryLog",
                                            global::SinoSZClientSysManager.Properties.Resources.e18, 80, _md);
                break;

            case "Notify":    //通知通告
                _md       = new MenuCommandDefine("Notify", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "Notify",
                                            global::SinoSZClientSysManager.Properties.Resources.e18, 80, _md);
                break;

            case "InterfaceManager_SJJH":
                _md       = new MenuCommandDefine("InterfaceManager_SJJH", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "InterfaceManager_SJJH",
                                            global::SinoSZClientSysManager.Properties.Resources.e18, 80, _md);
                break;

            case "FSDataLoadAlertMailSet":      //数据加载监控提示邮件设置
                _md       = new MenuCommandDefine("FSDataLoadAlertMailSet", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "FSDataLoadAlertMailSet",
                                            global::SinoSZClientSysManager.Properties.Resources.e15, 80, _md);
                break;

            case "TaskManager":    //后台工作任务管理器
                _md       = new MenuCommandDefine("TaskManager", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "TaskManager",
                                            global::SinoSZClientSysManager.Properties.Resources.e15, 80, _md);
                break;

            case "WorkCalendar":    //工作日历
                _md       = new MenuCommandDefine("WorkCalendar", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "WorkCalendar",
                                            global::SinoSZClientSysManager.Properties.Resources.t7, 80, _md);
                break;

            case "GDSManager":
                _md       = new MenuCommandDefine("GDSManager", _displayTitle, this as IMenuCommand, _param);
                _menuItem = new FrmMenuItem(_displayTitle, "GDSManager",
                                            global::SinoSZClientSysManager.Properties.Resources.t7, 80, _md);
                break;
            }
            return(_menuItem);
        }