mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-04-24 18:04:52 +08:00
Update Filter
This commit is contained in:
parent
5f42b14493
commit
d53d61a5c1
@ -340,7 +340,10 @@ namespace SqlSugar
|
||||
}
|
||||
if (isSingle)
|
||||
{
|
||||
|
||||
if (ChildType != this.EntityType)
|
||||
{
|
||||
return;
|
||||
}
|
||||
}
|
||||
else if (isMain)
|
||||
{
|
||||
@ -352,6 +355,10 @@ namespace SqlSugar
|
||||
var easyInfo = EasyJoinInfos.FirstOrDefault(it =>
|
||||
it.Value.Equals(entityInfo.DbTableName, StringComparison.CurrentCultureIgnoreCase) ||
|
||||
it.Value.Equals(entityInfo.EntityName, StringComparison.CurrentCultureIgnoreCase));
|
||||
if (easyInfo.Key==null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
var shortName = this.Builder.GetTranslationColumnName(easyInfo.Key.Trim()) + ".";
|
||||
sql = sql.Replace(itName, shortName);
|
||||
}
|
||||
@ -360,6 +367,10 @@ namespace SqlSugar
|
||||
var easyInfo = JoinQueryInfos.FirstOrDefault(it =>
|
||||
it.TableName.Equals(entityInfo.DbTableName, StringComparison.CurrentCultureIgnoreCase) ||
|
||||
it.TableName.Equals(entityInfo.EntityName, StringComparison.CurrentCultureIgnoreCase));
|
||||
if (easyInfo == null)
|
||||
{
|
||||
return;
|
||||
}
|
||||
var shortName = this.Builder.GetTranslationColumnName(easyInfo.ShortName.Trim()) + ".";
|
||||
sql = sql.Replace(itName, shortName);
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user