mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-18 09:44:39 +08:00
Bind Bug
This commit is contained in:
@@ -168,6 +168,7 @@ namespace SqlSugar
|
|||||||
{
|
{
|
||||||
case CSharpDataType.@int:
|
case CSharpDataType.@int:
|
||||||
CheckType(bind.IntThrow, bindProperyTypeName, validPropertyName, propertyName);
|
CheckType(bind.IntThrow, bindProperyTypeName, validPropertyName, propertyName);
|
||||||
|
if (bindProperyTypeName.IsContainsIn("int","int32","int64"))
|
||||||
method = isNullableType ? getConvertInt32 : getInt32;
|
method = isNullableType ? getConvertInt32 : getInt32;
|
||||||
break;
|
break;
|
||||||
case CSharpDataType.@bool:
|
case CSharpDataType.@bool:
|
||||||
@@ -220,7 +221,7 @@ namespace SqlSugar
|
|||||||
method = getConvertString;
|
method = getConvertString;
|
||||||
}
|
}
|
||||||
if (method == null)
|
if (method == null)
|
||||||
method = getOtherNull.MakeGenericMethod(bindPropertyType);
|
method =isNullableType? getOtherNull.MakeGenericMethod(bindPropertyType):getOther.MakeGenericMethod(bindPropertyType);
|
||||||
generator.Emit(OpCodes.Call, method);
|
generator.Emit(OpCodes.Call, method);
|
||||||
if (method == getValueMethod)
|
if (method == getValueMethod)
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user