mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2026-02-27 16:50:33 +08:00
Synchronization code
This commit is contained in:
@@ -54,7 +54,14 @@ namespace SqlSugar
|
|||||||
if (propertyInfo != null)
|
if (propertyInfo != null)
|
||||||
{
|
{
|
||||||
// 如果找到了该属性,则将其值设置为字典中对应的值
|
// 如果找到了该属性,则将其值设置为字典中对应的值
|
||||||
propertyInfo.SetValue(obj, Convert.ChangeType(pair.Value, propertyInfo.PropertyType));
|
if (pair.Value == null)
|
||||||
|
{
|
||||||
|
propertyInfo.SetValue(obj, UtilMethods.ChangeType2(pair.Value, propertyInfo.PropertyType));
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
propertyInfo.SetValue(obj, Convert.ChangeType(pair.Value, propertyInfo.PropertyType));
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user