mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-09-18 01:15:34 +08:00
- 补充 IDbFirst GetTableByDatabase 返回 uk/fk/index 名称,以便迁移;
This commit is contained in:
@@ -38,6 +38,10 @@ namespace FreeSql.DataAnnotations {
|
||||
/// </summary>
|
||||
public bool IsVersion { get => _IsVersion ?? false; set => _IsVersion = value; }
|
||||
|
||||
/// <summary>
|
||||
/// 唯一键,多个属性指定相同的标识,代表联合键
|
||||
/// </summary>
|
||||
public string Unique { get; set; }
|
||||
/// <summary>
|
||||
/// 数据库默认值
|
||||
/// </summary>
|
||||
|
@@ -65,6 +65,15 @@ namespace FreeSql.DataAnnotations {
|
||||
return this;
|
||||
}
|
||||
/// <summary>
|
||||
/// 唯一键,多个属性指定相同的标识,代表联合键
|
||||
/// </summary>
|
||||
/// <param name="value">标识</param>
|
||||
/// <returns></returns>
|
||||
public ColumnFluent Unique(string value) {
|
||||
_column.Unique = value;
|
||||
return this;
|
||||
}
|
||||
/// <summary>
|
||||
/// 类型映射,比如:可将 enum 属性映射成 typeof(string)
|
||||
/// </summary>
|
||||
/// <param name="type"></param>
|
||||
|
Reference in New Issue
Block a user