using System; using System.Collections.Generic; using System.ComponentModel.DataAnnotations.Schema; namespace Oqtane.Models { /// /// Describes a Page in Oqtane /// public class Page : IAuditable, IDeletable { /// /// Id of the Page /// public int PageId { get; set; } /// /// Reference to the . /// public int SiteId { get; set; } /// /// Reference to the parent if it has one. /// public int? ParentId { get; set; } /// /// Page Name. /// TODO: todoc where this is used /// public string Name { get; set; } /// /// Page Title which is shown in the browser tab. /// public string Title { get; set; } /// /// Path of the page. /// TODO: todoc relative to what? site root, parent-page, domain? /// public string Path { get; set; } /// /// Sort order in the list of other sibling pages /// public int Order { get; set; } /// /// Full URL to this page. /// TODO: verify that this is the case - does it contain domain etc. or just from domain or alias root? /// public string Url { get; set; } /// /// Reference to a which will be used to show this page. /// public string ThemeType { get; set; } /// /// Reference to a Container which will be used for modules on this page. /// public string DefaultContainerType { get; set; } /// /// Icon file for this page. /// TODO: unclear what this is for, and what icon library is used. Probably FontAwesome? /// public string Icon { get; set; } public bool IsNavigation { get; set; } public bool IsClickable { get; set; } public int? UserId { get; set; } public bool IsPersonalizable { get; set; } #region IAuditable Properties /// public string CreatedBy { get; set; } /// public DateTime CreatedOn { get; set; } /// public string ModifiedBy { get; set; } /// public DateTime ModifiedOn { get; set; } #endregion #region Extended IAuditable Properties, may be moved to an Interface some day so not documented yet public string DeletedBy { get; set; } public DateTime? DeletedOn { get; set; } public bool IsDeleted { get; set; } #endregion /// /// List of Pane-names which this Page has. /// [NotMapped] public List Panes { get; set; } /// /// List of (CSS, JS) which this page needs to render properly. /// [NotMapped] public List Resources { get; set; } [NotMapped] public string Permissions { get; set; } [NotMapped] public Dictionary Settings { get; set; } [NotMapped] public int Level { get; set; } /// /// Determines if there are sub-pages. True if this page has sub-pages. /// [NotMapped] public bool HasChildren { get; set; } #region Deprecated Properties [Obsolete("This property is deprecated", false)] [NotMapped] public bool EditMode { get; set; } [Obsolete("This property is deprecated", false)] [NotMapped] public string LayoutType { get; set; } #endregion } }