using System; using System.Diagnostics; namespace zero.Core.Entities { [DebuggerDisplay("Id = {Id,nq}, Name = {Name}, Alias = {Alias}")] public abstract class ZeroEntity : IZeroEntity { /// public string Id { get; set; } /// public string AppId { get; set; } /// public string Name { get; set; } /// public string Alias { get; set; } /// public uint Sort { get; set; } /// public bool IsActive { get; set; } /// public string LastModifiedById { get; set; } /// public DateTimeOffset LastModifiedDate { get; set; } /// public string CreatedById { get; set; } /// public DateTimeOffset CreatedDate { get; set; } /// public BlueprintConfiguration Blueprint { get; set; } } public interface IZeroEntity : IZeroIdEntity, IAppAwareEntity { /// /// Full name of the entity /// string Name { get; set; } /// /// Unique alias which can be used in the frontend and URLs /// As generating aliases from the name would not be unique we append an incremental number if the desired alias is not available anymore /// string Alias { get; set; } /// /// Sort order /// uint Sort { get; set; } /// /// Whether the entity is visible in the frontend /// bool IsActive { get; set; } /// /// Backoffice user who last modified this content /// public string LastModifiedById { get; set; } /// /// Date of last modification /// DateTimeOffset LastModifiedDate { get; set; } /// /// Backoffice user who created this content /// [Overwrite] public string CreatedById { get; set; } /// /// Date of creation /// DateTimeOffset CreatedDate { get; set; } /// /// Configuration of the base entity (which this one inherits from) /// BlueprintConfiguration Blueprint { get; set; } } }