mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-05-05 05:07:57 +08:00
Update CreateObjectByType
This commit is contained in:
parent
ef5a7605cb
commit
3c8d03c29a
@ -54,7 +54,7 @@ namespace SqlSugar
|
|||||||
if (propertyInfo != null)
|
if (propertyInfo != null)
|
||||||
{
|
{
|
||||||
// 如果找到了该属性,则将其值设置为字典中对应的值
|
// 如果找到了该属性,则将其值设置为字典中对应的值
|
||||||
if (pair.Value == null)
|
if (pair.Value == null||UtilMethods.GetUnderType( propertyInfo.PropertyType)==UtilConstants.GuidType)
|
||||||
{
|
{
|
||||||
propertyInfo.SetValue(obj, UtilMethods.ChangeType2(pair.Value, propertyInfo.PropertyType));
|
propertyInfo.SetValue(obj, UtilMethods.ChangeType2(pair.Value, propertyInfo.PropertyType));
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user