Beispiel #1
0
 private void BindManageMenuTreeByApplicationIDAndSelectNodeID(string appID, string selectNodeID)
 {
     if (appID != "")
     {
         int selectAppId             = int.Parse(appID);
         SystemApplication selectApp = systemApplicationServiceInstance.FindById(selectAppId);
         if (selectApp != null)
         {
             this.tvMenus.Nodes.Clear();
             this.tvMenus.Nodes.Add(systemMenuServiceInstance.GenerateManageWebTreeNodeByApplication(selectApp, this.ResolveUrl("~/images/Menu/control_panel.gif"), this.ResolveUrl("~/images/Menu/folders.gif"), this.ResolveUrl("~/images/Menu/folder.gif")));
         }
         TreeNode selectNode;
         if (selectNodeID == "0")
         {
             selectNode = this.tvMenus.Nodes[0];
             selectNode.Select();
         }
         else
         {
             selectNode = TreeViewHelper.GetWebTreeViewNodeByValue(this.tvMenus, selectNodeID.ToString());
             selectNode.Select();
         }
         SelectNode(selectNode);
         this.tvMenus.ExpandAll();
     }
 }