mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-10-07 07:04:32 +08:00
Update exp to sql
This commit is contained in:
@@ -593,7 +593,7 @@ namespace SqlSugar
|
||||
}
|
||||
}
|
||||
|
||||
private string ReplaceFilterColumnName(string sql, Type filterType,string shortName=null)
|
||||
internal string ReplaceFilterColumnName(string sql, Type filterType,string shortName=null)
|
||||
{
|
||||
foreach (var column in this.Context.EntityMaintenance.GetEntityInfoWithAttr(filterType).Columns.Where(it => it.IsIgnore == false))
|
||||
{
|
||||
|
@@ -64,6 +64,11 @@ namespace SqlSugar
|
||||
var whereStr = isWhere ? " AND " : " WHERE ";
|
||||
isWhere = true;
|
||||
result += (whereStr + SubTools.GetMethodValue(Context, exp, ResolveExpressType.WhereSingle));
|
||||
if (ChildType.IsInterface&& this.Context?.SugarContext?.QueryBuilder!=null)
|
||||
{
|
||||
var filterType = ChildType;
|
||||
result =this.Context.SugarContext?.QueryBuilder.ReplaceFilterColumnName(result, type);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user