mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-06-28 13:34:32 +08:00
Update exp to sql
This commit is contained in:
parent
48e656f60b
commit
14c5a36f37
@ -67,6 +67,22 @@ namespace SqlSugar
|
|||||||
}
|
}
|
||||||
this.Context.SugarContext.QueryBuilder.SelectNewIgnoreColumns.Add(new KeyValuePair<string, string>(ignoreProperty.Name, itemType.Name));
|
this.Context.SugarContext.QueryBuilder.SelectNewIgnoreColumns.Add(new KeyValuePair<string, string>(ignoreProperty.Name, itemType.Name));
|
||||||
}
|
}
|
||||||
|
if (this.Context?.SugarContext?.Context != null)
|
||||||
|
{
|
||||||
|
var entityInfoColumns = this.Context?.SugarContext?.Context.EntityMaintenance.GetEntityInfo(item.Type)
|
||||||
|
.Columns
|
||||||
|
.Where(it=>it.PropertyInfo!=ignoreProperty)
|
||||||
|
.Where(it=>it.IsIgnore==true)
|
||||||
|
.Where(it => it.PropertyInfo.PropertyType.IsClass()).ToList();
|
||||||
|
foreach (var itemColumnInfo in entityInfoColumns)
|
||||||
|
{
|
||||||
|
if (this.Context.SugarContext.QueryBuilder.SelectNewIgnoreColumns == null)
|
||||||
|
{
|
||||||
|
this.Context.SugarContext.QueryBuilder.SelectNewIgnoreColumns = new List<KeyValuePair<string, string>>();
|
||||||
|
}
|
||||||
|
this.Context.SugarContext.QueryBuilder.SelectNewIgnoreColumns.Add(new KeyValuePair<string, string>(itemColumnInfo.PropertyInfo.Name, itemType.Name));
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
if (item is ConstantExpression)
|
if (item is ConstantExpression)
|
||||||
{
|
{
|
||||||
|
Loading…
Reference in New Issue
Block a user