Пример #1
0
        public void NavigationWorkPanel(string tag)
        {
            try
            {
                WorkHost.PanelContent = null;
                if (!bMVCOpen)
                {
                    WorkHost.Visibility = Visibility.Visible;
                }
                //WebPartHost.Visibility = Visibility.Collapsed;
                //WebPartHost.Stop();

                UserControl workitem = null;
                string      titel    = "";
                switch (tag)
                {
                case "NewsManager": workitem = new WebParts.Views.NewsManager(); titel = "新闻管理"; break;

                case "SystemLog": workitem = new SMT.SAAS.Platform.Xamls.SystemLogger(); titel = " 系统日志"; break;

                case "CustomMenusSet":
                {
                    titel = "菜单列表";
                    if (_mainMenu == null)
                    {
                        _mainMenu = new Xamls.MainPagePart.MenusPanel();
                        _mainMenu.ShortCutClick += new EventHandler <OnShortCutClickEventArgs>(menu_ShortCutClick);
                        workitem = _mainMenu;
                    }
                    else
                    {
                        workitem = _mainMenu;
                    }
                    break;
                }

                default: break;
                }

                WorkHost.Navigation(workitem, titel);
                Common.AppContext.IsMenuOpen = _fromMenu;
            }
            catch (Exception ex)
            {
                string strmsg = "点击菜单时发生错误,原因:" + ex.ToString();
                SMT.SAAS.Main.CurrentContext.AppContext.SystemMessage(strmsg);
            }
            finally
            {
                hideLoadingBar();
                HtmlPage.Window.Invoke("loadCompletedSL", "Invoke");
            }
        }
Пример #2
0
        public void NavigationWorkPanel(string tag)
        {
            try
            {
                WorkHost.PanelContent  = null;
                WorkHost.Visibility    = Visibility.Visible;
                WebPartHost.Visibility = Visibility.Collapsed;
                WebPartHost.Stop();

                UserControl workitem = null;
                string      titel    = "";
                switch (tag)
                {
                case "NewsManager": workitem = new WebParts.Views.NewsManager(); titel = "新闻管理"; break;

                //case "SystemLog": workitem = new SMT.SAAS.Platform.Xamls.SystemLogger(); titel = " 系统日志"; break;
                case "CustomMenusSet":
                {
                    titel = "菜单列表";
                    if (MenuPanel == null)
                    {
                        MenuPanel = new Xamls.MainPagePart.MenusPanel();
                        MenuPanel.MenuItemMouseDown += new EventHandler <MouseButtonEventArgs>(menu_MenuItemMouseDown);
                        MenuPanel.ShortCutClick     += new EventHandler <OnShortCutClickEventArgs>(menu_ShortCutClick);
                        MenuPanel.MenuItemMouseMove += new EventHandler <MouseEventArgs>(menu_MenuItemMouseMove);
                        workitem = MenuPanel;
                    }
                    else
                    {
                        workitem = MenuPanel;
                    }
                    break;
                }

                default: break;
                }

                WorkHost.Navigation(workitem, titel);
                Common.AppContext.IsMenuOpen = _fromMenu;
            }
            catch (Exception ex)
            {
                string strmsg = "点击菜单时发生错误,原因:" + ex.ToString();
                SMT.SAAS.Main.CurrentContext.AppContext.SystemMessage(strmsg);
            }
        }
Пример #3
0
        public void NavigationWorkPanel(string tag)
        {
            try
            {
                WorkHost.PanelContent = null;
                if (!bMVCOpen)
                {
                    WorkHost.Visibility = Visibility.Visible;
                }
                //WebPartHost.Visibility = Visibility.Collapsed;
                //WebPartHost.Stop();

                UserControl workitem = null;
                string titel = "";
                switch (tag)
                {
                    case "NewsManager": workitem = new WebParts.Views.NewsManager(); titel = "新闻管理"; break;
                    case "SystemLog": workitem = new SMT.SAAS.Platform.Xamls.SystemLogger(); titel = " 系统日志"; break;
                    case "CustomMenusSet":
                        {
                            titel = "菜单列表";
                            if (_mainMenu == null)
                            {
                                _mainMenu = new Xamls.MainPagePart.MenusPanel();
                                _mainMenu.ShortCutClick += new EventHandler<OnShortCutClickEventArgs>(menu_ShortCutClick);
                                workitem = _mainMenu;
                            }
                            else
                            {
                                workitem = _mainMenu;
                            }
                            break;
                        }
                    default: break;
                }

                WorkHost.Navigation(workitem, titel);
                Common.AppContext.IsMenuOpen = _fromMenu;

            }
            catch (Exception ex)
            {
                string strmsg = "点击菜单时发生错误,原因:" + ex.ToString();
                SMT.SAAS.Main.CurrentContext.AppContext.SystemMessage(strmsg);
            }
            finally
            {
                hideLoadingBar();
                HtmlPage.Window.Invoke("loadCompletedSL", "Invoke");
            }
        }
Пример #4
0
        public void NavigationWorkPanel(string tag)
        {
            try
            {
                WorkHost.PanelContent = null;
                WorkHost.Visibility = Visibility.Visible;
                WebPartHost.Visibility = Visibility.Collapsed;
                WebPartHost.Stop();

                UserControl workitem = null;
                string titel = "";
                switch (tag)
                {
                    case "NewsManager": workitem = new WebParts.Views.NewsManager(); titel = "新闻管理"; break;
                    //case "SystemLog": workitem = new SMT.SAAS.Platform.Xamls.SystemLogger(); titel = " 系统日志"; break;
                    case "CustomMenusSet":
                        {
                            titel = "菜单列表";
                            if (MenuPanel == null)
                            {
                                MenuPanel = new Xamls.MainPagePart.MenusPanel();
                                MenuPanel.MenuItemMouseDown += new EventHandler<MouseButtonEventArgs>(menu_MenuItemMouseDown);
                                MenuPanel.ShortCutClick += new EventHandler<OnShortCutClickEventArgs>(menu_ShortCutClick);
                                MenuPanel.MenuItemMouseMove += new EventHandler<MouseEventArgs>(menu_MenuItemMouseMove);
                                workitem = MenuPanel;
                            }
                            else
                            {
                                workitem = MenuPanel;
                            }
                            break;
                        }
                    default: break;
                }

                WorkHost.Navigation(workitem, titel);
                Common.AppContext.IsMenuOpen = _fromMenu;
            }
            catch (Exception ex)
            {
                string strmsg = "点击菜单时发生错误,原因:" + ex.ToString();
                SMT.SAAS.Main.CurrentContext.AppContext.SystemMessage(strmsg);
            }
        }