mirror of
https://gitee.com/dotnetchina/SqlSugar.git
synced 2025-09-20 10:38:09 +08:00
Synchronization code
This commit is contained in:
@@ -1078,8 +1078,16 @@ namespace SqlSugar
|
||||
}
|
||||
public ISugarQueryable<T> OrderByPropertyName(string orderPropertyName, OrderByType? orderByType = null)
|
||||
{
|
||||
if (orderPropertyName != null)
|
||||
if (orderPropertyName.HasValue())
|
||||
{
|
||||
if (orderPropertyName.Contains(","))
|
||||
{
|
||||
foreach (var item in orderPropertyName.Split(','))
|
||||
{
|
||||
this.OrderByPropertyName(item,orderByType);
|
||||
}
|
||||
return this;
|
||||
}
|
||||
if (this.Context.EntityMaintenance.GetEntityInfoWithAttr(typeof(T)).Columns.Any(it =>
|
||||
it.DbColumnName?.EqualCase(orderPropertyName)==true
|
||||
|| it.PropertyName?.EqualCase(orderPropertyName)==true))
|
||||
|
Reference in New Issue
Block a user