Example #1
0
 /// <summary>
 /// 添加左侧菜单
 /// </summary>
 /// <param name="menuId">一级菜单的Tag 菜单id</param>
 /// <param name="munuName">菜单名</param>
 private void AddLeftMenu(string menuId, string munuName)
 {
     SYSModel.clsSysConfig.STR_CURR_MAINMEMU = menuId;
     if (panel_LeftMenu.Controls.Find(menuId, true).Length == 0)
     {
         UCMainLayOut.UCLeftMenu UCLeftMenu = new UCMainLayOut.UCLeftMenu(); //系统管理
         UCLeftMenu.Name = menuId;                                           //SYSModel.clsSysConfig.STR_CS_MEMU_FUNCTIONMANAGE;
         // UCLeftMenu.dtFunction = dt;
         UCLeftMenu.FunID = menuId;
         //UCLeftMenu.panel_MainHeight = pnlxLeftMenu.Height;
         UCLeftMenu.Dock     = DockStyle.Fill;
         UCLeftMenu.Tag      = munuName;
         UCLeftMenu.menuName = munuName;
         UCLeftMenu.FmMain   = this;
         UCLeftMenu.Focus();
         panel_LeftMenu.Controls.Add(UCLeftMenu);
         UCLeftMenu.BringToFront();
     }
     else
     {
         UCMainLayOut.UCLeftMenu UCLeftMenu = panel_LeftMenu.Controls.Find(menuId, true)[0] as UCMainLayOut.UCLeftMenu;
         UCLeftMenu.LeftMenuState(SYSModel.clsSysConfig.STR_CURR_TWOMEMU, SYSModel.clsSysConfig.STR_CURR_MEMU, SYSModel.clsSysConfig.STR_CURR_MEMU);
         UCLeftMenu.BringToFront();
     }
 }
Example #2
0
        /// <summary> 加载首页
        /// </summary>
        private void loadHome()
        {
            splitContainerEx_Body.SplitterWidth     = 6;
            SYSModel.clsSysConfig.STR_CURR_MAINMEMU = "S_SysMaintenance";
            if (panel_LeftMenu.Controls.Find("S_SysMaintenance", true).Length == 0)
            {
                UCMainLayOut.UCLeftMenu UCLeftMenu = new UCMainLayOut.UCLeftMenu(); //系统管理
                UCLeftMenu.Name = "S_SysMaintenance";                               //EntityModel.clsSysConfig.STR_CS_MEMU_FUNCTIONMANAGE;
                // UCLeftMenu.dtFunction = dt;
                UCLeftMenu.FunID = "S_SysMaintenance";
                //UCLeftMenu.panel_MainHeight = pnlxLeftMenu.Height;
                UCLeftMenu.Dock     = DockStyle.Fill;
                UCLeftMenu.Tag      = "系统管理";
                UCLeftMenu.menuName = "系统管理";
                UCLeftMenu.FmMain   = this;
                UCLeftMenu.Focus();
                panel_LeftMenu.Controls.Add(UCLeftMenu);
                UCLeftMenu.BringToFront();

                SYSModel.clsSysConfig.STR_CURR_MAINMEMU = UCLeftMenu.FunID;
                ucMenu.MenuButtonStatus();                            //三级菜单选中时 一级菜单的选中状态

                UCForm.UUCHomePage ucHome = new UCForm.UUCHomePage(); //首页
                // home.ID = "STR_" + STR_CS_MEMU_NAME;
                ucHome.ID   = "STR_" + SYSModel.clsSysConfig.STR_CS_MEMU_HOMEMANAGE;
                ucHome.Name = SYSModel.clsSysConfig.STR_CS_MEMU_HOMEMANAGE;
                ucHome.Dock = DockStyle.Fill;
                ucHome.Focus();
                panel_Content.Controls.Add(ucHome);// panel_Main.Controls.Add(ucHome);
                ucHome.BringToFront();
                childmemu(null, "首页", SYSModel.clsSysConfig.STR_CS_MEMU_HOMEMANAGE, "", UCLeftMenu.Name, "");
            }
            else
            {
                (panel_LeftMenu.Controls.Find("CL_SystemManagement", true)[0] as UCMainLayOut.UCLeftMenu).BringToFront();
            }
        }
 /// <summary>
 /// 添加左侧菜单
 /// </summary>
 /// <param name="menuId">一级菜单的Tag 菜单id</param>
 /// <param name="munuName">菜单名</param>
 private void AddLeftMenu(string menuId, string munuName)
 {
     SYSModel.clsSysConfig.STR_CURR_MAINMEMU = menuId;
     if (panel_LeftMenu.Controls.Find(menuId, true).Length == 0)
     {
         UCMainLayOut.UCLeftMenu UCLeftMenu = new UCMainLayOut.UCLeftMenu(); //系统管理
         UCLeftMenu.Name = menuId;//SYSModel.clsSysConfig.STR_CS_MEMU_FUNCTIONMANAGE;
         // UCLeftMenu.dtFunction = dt;
         UCLeftMenu.FunID = menuId;
         //UCLeftMenu.panel_MainHeight = pnlxLeftMenu.Height;
         UCLeftMenu.Dock = DockStyle.Fill;
         UCLeftMenu.Tag = munuName;
         UCLeftMenu.menuName = munuName;
         UCLeftMenu.FmMain = this;
         UCLeftMenu.Focus();
         panel_LeftMenu.Controls.Add(UCLeftMenu);
         UCLeftMenu.BringToFront();
     }
     else
     {
         UCMainLayOut.UCLeftMenu UCLeftMenu = panel_LeftMenu.Controls.Find(menuId, true)[0] as UCMainLayOut.UCLeftMenu;
         UCLeftMenu.LeftMenuState(SYSModel.clsSysConfig.STR_CURR_TWOMEMU, SYSModel.clsSysConfig.STR_CURR_MEMU, SYSModel.clsSysConfig.STR_CURR_MEMU);
         UCLeftMenu.BringToFront();
     }
 }
        /// <summary> 加载首页
        /// </summary>
        private void loadHome()
        {
            splitContainerEx_Body.SplitterWidth = 6;
            SYSModel.clsSysConfig.STR_CURR_MAINMEMU = "S_SysMaintenance";
            if (panel_LeftMenu.Controls.Find("S_SysMaintenance", true).Length == 0)
            {
                UCMainLayOut.UCLeftMenu UCLeftMenu = new UCMainLayOut.UCLeftMenu(); //系统管理
                UCLeftMenu.Name = "S_SysMaintenance";//EntityModel.clsSysConfig.STR_CS_MEMU_FUNCTIONMANAGE;
                // UCLeftMenu.dtFunction = dt;
                UCLeftMenu.FunID = "S_SysMaintenance";
                //UCLeftMenu.panel_MainHeight = pnlxLeftMenu.Height;
                UCLeftMenu.Dock = DockStyle.Fill;
                UCLeftMenu.Tag = "系统管理";
                UCLeftMenu.menuName = "系统管理";
                UCLeftMenu.FmMain = this;
                UCLeftMenu.Focus();
                panel_LeftMenu.Controls.Add(UCLeftMenu);
                UCLeftMenu.BringToFront();

                SYSModel.clsSysConfig.STR_CURR_MAINMEMU = UCLeftMenu.FunID;
                ucMenu.MenuButtonStatus();//三级菜单选中时 一级菜单的选中状态

                UCForm.UUCHomePage ucHome = new UCForm.UUCHomePage(); //首页
                // home.ID = "STR_" + STR_CS_MEMU_NAME;
                ucHome.ID = "STR_" + SYSModel.clsSysConfig.STR_CS_MEMU_HOMEMANAGE;
                ucHome.Name = SYSModel.clsSysConfig.STR_CS_MEMU_HOMEMANAGE;
                ucHome.Dock = DockStyle.Fill;
                ucHome.Focus();
                panel_Content.Controls.Add(ucHome);// panel_Main.Controls.Add(ucHome);
                ucHome.BringToFront();
                childmemu(null, "首页", SYSModel.clsSysConfig.STR_CS_MEMU_HOMEMANAGE, "", UCLeftMenu.Name, "");
            }
            else
            {
                (panel_LeftMenu.Controls.Find("CL_SystemManagement", true)[0] as UCMainLayOut.UCLeftMenu).BringToFront();
            }
        }