mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-19 20:38:16 +08:00
- 增加 ExpressionCallAttribute 特性,实现表达式函数自定义解析;
This commit is contained in:
@ -170,10 +170,7 @@ namespace FreeSql.Internal
|
||||
if (colattr.IsNullable == false && colattr.DbDefautValue == null)
|
||||
{
|
||||
var citype = colattr.MapType.IsNullableType() ? colattr.MapType.GetGenericArguments().FirstOrDefault() : colattr.MapType;
|
||||
if (citype.IsArray)
|
||||
colattr.DbDefautValue = Array.CreateInstance(citype, 0);
|
||||
else
|
||||
colattr.DbDefautValue = Activator.CreateInstance(citype);
|
||||
colattr.DbDefautValue = citype.CreateInstanceGetDefaultValue();
|
||||
}
|
||||
|
||||
trytb.Columns.Add(colattr.Name, col);
|
||||
|
Reference in New Issue
Block a user