Refer to the Sorting in ListView/NestedListView in servermode ticket for a workaround.
Core - Pass sorting options from the application model into PropertyCollectionSource
Answers approved by DevExpress Support
We have implemented the functionality described in this ticket. It will be included in our next update(s).
Please check back and leave a comment to this response to let us know whether or not this solution addresses your concerns.
We have added the CollectionSourceBase.CanApplySorting property. When it is set to true, sorting options specified in the application model are applied.
In the CollectionSource descendant, the default value of this property is true. In the PropertyCollectionSource descendant the default value is false. This is done to avoid accidental overriding of sorting specified in a collection property getter. You can customize this behavior via a ViewController:
C#using System;
using System.Collections.Generic;
using System.Linq;
using DevExpress.ExpressApp;
namespace YourSolutionName.Module {
public class ViewController1: ViewController<ListView> {
public ViewController1() {
TargetViewNesting = DevExpress.ExpressApp.Nesting.Nested;
}
protected override void OnActivated() {
base.OnActivated();
View.CollectionSource.CanApplySorting = true;
}
}
}
- v13.1.4Download Official Update