using System; using System.ComponentModel.DataAnnotations; namespace Infrastructure.Domain { public abstract class BaseEntity { public BaseEntity() { this.Id = Guid.NewGuid(); } [Display(Name = "Id")] public Guid Id { get; set; } [Display(Name = "已删除")] public string IsDeleted { get; set; } [Display(Name = "添加人员")] public string CreateBy { get; set; } [Display(Name = "添加时间")] public DateTime CreateOn { get; set; } [Display(Name = "修改人员")] public string UpdateBy { get; set; } [Display(Name = "修改时间")] public DateTime? UpdateOn { get; set; } public override string ToString() { return $"{ GetType().FullName}[{Id}]"; } } }