You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
71 lines
1.9 KiB
C#
71 lines
1.9 KiB
C#
12 months ago
|
using System.ComponentModel;
|
||
|
|
||
|
namespace DS.Module.Core.Data;
|
||
|
|
||
|
/// <summary>
|
||
|
/// 实体类基类
|
||
|
/// </summary>
|
||
|
public abstract class BaseModel<TKey>
|
||
|
{
|
||
|
/// <summary>
|
||
|
/// 主键ID
|
||
|
/// </summary>
|
||
|
[Description("主键ID")]
|
||
|
[SqlSugar.SugarColumn(IsPrimaryKey = true, Length = 100, ColumnDescription = "主键ID")]
|
||
|
public TKey Id { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 备注
|
||
|
/// </summary>
|
||
|
[Description("备注")]
|
||
|
public string Note { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 创建时间
|
||
|
/// </summary>
|
||
|
[Description("创建时间")]
|
||
|
[SqlSugar.SugarColumn(IsOnlyIgnoreUpdate = true, ColumnDescription = "创建时间")]
|
||
|
public DateTime AddTime { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 创建人
|
||
|
/// </summary>
|
||
|
[Description("创建人")]
|
||
|
[SqlSugar.SugarColumn(IsOnlyIgnoreUpdate = true, IsNullable = true, ColumnDescription = "创建人")]
|
||
|
public string AddBy { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 修改人
|
||
|
/// </summary>
|
||
|
[Description("修改人")]
|
||
|
[SqlSugar.SugarColumn(IsNullable = true, ColumnDescription = "修改人")]
|
||
|
public string UpdateBy { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 更新时间
|
||
|
/// </summary>
|
||
|
[Description("更新时间")]
|
||
|
[SqlSugar.SugarColumn(ColumnDescription = "更新时间")]
|
||
|
public DateTime UpdateTime { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 删除
|
||
|
/// </summary>
|
||
|
[Description("删除")]
|
||
|
[SqlSugar.SugarColumn(ColumnDescription = "是否删除")]
|
||
|
public bool Deleted { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 删除时间
|
||
|
/// </summary>
|
||
|
[Description("删除时间")]
|
||
|
[SqlSugar.SugarColumn(ColumnDescription = "删除时间")]
|
||
|
public DateTime DeleteTime { get; set; }
|
||
|
|
||
|
/// <summary>
|
||
|
/// 删除人
|
||
|
/// </summary>
|
||
|
[Description("删除人")]
|
||
|
[SqlSugar.SugarColumn(IsNullable = true, ColumnDescription = "删除人")]
|
||
|
public string DeleteBy { get; set; }
|
||
|
}
|