Synchronization code

This commit is contained in:
sunkaixuan 2023-11-03 17:44:22 +08:00
parent 5e667d9f43
commit 15d10dba2a

View File

@ -43,7 +43,11 @@ namespace SqlSugar
orderByModel.AsName = orderByModel.AsName.Trim('[').Trim(']');
return this.SqlTranslationLeft + orderByModel.AsName + this.SqlTranslationRight;
}
return this.GetTranslationColumnName(orderByModel.AsName);
if (this.SqlTranslationLeft != null && orderByModel.AsName?.Contains(this.SqlTranslationLeft) == true)
{
return orderByModel.AsName;
}
return this.SqlTranslationLeft + orderByModel.AsName + this.SqlTranslationRight;
}
private void AppendFiledName(StringBuilder sql, SelectModel orderByModel)