diff --git a/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/NavigatManager.cs b/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/NavigatManager.cs index 1ba1c7857..59f596690 100644 --- a/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/NavigatManager.cs +++ b/Src/Asp.Net/SqlSugar/Abstract/QueryableProvider/NavigatManager.cs @@ -357,6 +357,14 @@ namespace SqlSugar navObjectNamePropety.SetValue(item.Key, instance); } } + foreach (var item in list) + { + if (navObjectNamePropety.GetValue(item) == null) + { + var instance = Activator.CreateInstance(navObjectNamePropety.PropertyType, true); + navObjectNamePropety.SetValue(item, instance); + } + } } } }