mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-29 10:49:36 +08:00
BUG: Storageable enum primary key
This commit is contained in:
parent
19a50ff1af
commit
6dd5ed29cf
@ -539,6 +539,11 @@ namespace SqlSugar
|
||||
FieldValue = value.ObjToStringNew(),
|
||||
CSharpTypeName = column.PropertyInfo.PropertyType.Name
|
||||
});
|
||||
if(value is Enum&&this.Context.CurrentConnectionConfig?.MoreSettings?.TableEnumIsString!=true)
|
||||
{
|
||||
data.Value.FieldValue = Convert.ToInt64(value).ObjToString();
|
||||
data.Value.CSharpTypeName = "int";
|
||||
}
|
||||
//if (this.Context.CurrentConnectionConfig.DbType == DbType.PostgreSQL)
|
||||
//{
|
||||
// data.Value.FieldValueConvertFunc = it =>
|
||||
|
Loading…
Reference in New Issue
Block a user