基础表2增加默认值
This commit is contained in:
parent
803449bcaa
commit
0a85919d2d
|
@ -10,16 +10,16 @@ namespace Falcon.SugarApi.DatabaseDefinitions
|
|||
public abstract class SugarBasicTable2
|
||||
{
|
||||
/// <summary>
|
||||
/// 主键
|
||||
/// 主键 默认GUID 382c74c3-721d-4f34-80e5-57657b6cbc27
|
||||
/// </summary>
|
||||
[SugarColumn(IsPrimaryKey = true,ColumnDescription = "主键")]
|
||||
public string Id { get; set; } = "";
|
||||
[MaxLength(36)]
|
||||
public string Id { get; set; } = Guid.NewGuid().ToString();
|
||||
/// <summary>
|
||||
/// 创建时间
|
||||
/// </summary>
|
||||
[Required]
|
||||
[SugarColumn(ColumnDescription = "创建时间")]
|
||||
public DateTime CreateTime { get; set; } = DateTime.Now;
|
||||
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user