mirror of
https://github.com/nsnail/FreeSql.git
synced 2025-06-19 20:38:16 +08:00
- 优化 TableInfo 元数据对 interface 实现类 IsVirtual 重写的判断(增加 IsFinal == false);
This commit is contained in:
@ -84,10 +84,11 @@ namespace FreeSql.Internal
|
||||
{
|
||||
if (common.CodeFirst.IsLazyLoading)
|
||||
{
|
||||
var getIsVirtual = p.GetGetMethod()?.IsVirtual;// trytb.Type.GetMethod($"get_{p.Name}")?.IsVirtual;
|
||||
var setIsVirtual = setMethod?.IsVirtual;
|
||||
var getMethod = p.GetGetMethod();
|
||||
var getIsVirtual = getMethod?.IsVirtual == true && getMethod?.IsFinal == false;// trytb.Type.GetMethod($"get_{p.Name}")?.IsVirtual;
|
||||
var setIsVirtual = setMethod?.IsVirtual == true && setMethod?.IsFinal == false;
|
||||
if (getIsVirtual == true || setIsVirtual == true)
|
||||
propsLazy.Add(NaviteTuple.Create(p, getIsVirtual == true, setIsVirtual == true));
|
||||
propsLazy.Add(NaviteTuple.Create(p, getIsVirtual, setIsVirtual));
|
||||
}
|
||||
propsNavObjs.Add(p);
|
||||
continue;
|
||||
|
Reference in New Issue
Block a user