예제 #1
0
        public HierarchyCollectionModel GetRootLevel()
        {
            HierarchyCollectionModel ret = new HierarchyCollectionModel();

            ret.AddRange(this.Where(x => !x.ParentId.HasValue));
            return(ret);
        }
예제 #2
0
        public HierarchyModel(Guid id, string name, string desc, string pic, int posi)
        {
            Id          = id;
            Name        = name;
            Description = desc;
            Picture     = pic;
            Position    = posi;

            Descendance = new HierarchyCollectionModel();
        }
예제 #3
0
 public CatalogModel()
 {
     Hierarchy = new HierarchyCollectionModel();
 }