public PageValue SetCurrentPage(Guid pid) { if (pid == Guid.Empty || this.HasPages() == false) { return(null); } this.CurrentPage = this.Pages.SingleOrDefault(p => p.Page.Id == pid); return(CurrentPage); }
internal PageValue AddPages(Guid sectionId, Guid pid, string name, string content) { var st = this.GetSection(sectionId); var page = new PageValue(sectionId, this.Id, pid, name); st.AddPages(page); return(page); }
public void AddPages(PageValue item) { if (item == null) { return; } if (this.Pages == null) { this.Pages = new List <PageValue>(); } this.Pages.Add(item); this.CurrentPage = item; }