예제 #1
0
        public NavigationItemCollection GetChildItems(int id)
        {
            NavigationItemCollection items = new NavigationItemCollection();

            foreach (NavigationItem item in Navigations)
            {
                if (item.ParentID == id)
                {
                    items.Add(item);
                }
            }

            return(items);
        }
예제 #2
0
        public TopLinkSettings2()
        {
            Navigations = new NavigationItemCollection();

            MaxID = 0;

            MaxID++;
            NavigationItem item = new NavigationItem();

            item.ID              = MaxID;
            item.Name            = "首页";
            item.UrlInfo         = "index";
            item.NewWindow       = false;
            item.OnlyLoginCanSee = false;
            item.SortOrder       = MaxID;
            item.Type            = MaxLabs.bbsMax.Enums.NavigationType.Internal;
            item.IsTopLink       = true;

            Navigations.Add(item);
        }
예제 #3
0
        public NavigationSettings()
        {
            Navigations = new NavigationItemCollection();

            MaxID = 0;
            //foreach (KeyValuePair<string, string> pair in NavigationSettings.InternalLinks())
            //{
            //    if (pair.Key == "index")
            //    {
            MaxID++;
            NavigationItem item = new NavigationItem();

            item.ID              = MaxID;
            item.Name            = "首页";
            item.UrlInfo         = "index";
            item.NewWindow       = false;
            item.OnlyLoginCanSee = false;
            item.SortOrder       = MaxID;
            item.Type            = MaxLabs.bbsMax.Enums.NavigationType.Internal;

            Navigations.Add(item);
            //    }
            //}
        }