Enable ordering by level when getting page descendants of content

This commit is contained in:
Dave Woestenborghs
2020-10-12 15:59:35 +02:00
parent 549e7ce6de
commit af5d2851b0

View File

@@ -363,6 +363,9 @@ namespace Umbraco.Core.Persistence.Repositories.Implement
if (ordering.OrderBy.InvariantEquals("path"))
return GetAliasedField(SqlSyntax.GetFieldName<NodeDto>(x => x.Path), sql);
if (ordering.OrderBy.InvariantEquals("level"))
return GetAliasedField(SqlSyntax.GetFieldName<NodeDto>(x => x.Level), sql);
// note: 'owner' is the user who created the item as a whole,
// we don't have an 'owner' per culture (should we?)
if (ordering.OrderBy.InvariantEquals("owner"))