Selects from a set of predefined sorting definitions and directions.
<adf-sorting-picker
[options]="options"
[selected]="value"
[ascending]="ascending"
(change)="onChanged($event)">
</adf-sorting-picker>
Name | Type | Default value | Description |
---|---|---|---|
ascending | boolean | true | Current sorting direction |
options | Array<Function> | [] | Available sorting options |
selected | string | Currently selected option key |
Name | Type | Description |
---|---|---|
sortingChange | EventEmitter <boolean> | Raised each time direction gets changed. |
valueChange | EventEmitter <string> | Raised each time sorting key gets changed. |
The picker shows the user a menu of sorting options (which could be data columns to sort on alphabetical vs numerical search, etc) and the choice of ascending vs descending sort order. Note that picker only implements the menu, so you are responsible for implementing the sorting options yourself.
The options
property contains an array of any objects that expose the following properties:
{ key: string; label: string; }
The key
is an identifying value and the label
is the text that the user will see in the
picker. The selected key
is reported by the change
event, which passes an object like the
following as its parameter:
{ key: string, ascending: boolean }
© 2023 Alfresco Software, Inc. All Rights Reserved.
By using this site, you are agreeing to allow us to collect and use cookies as outlined in Alfresco’s Cookie Statement and Terms of Use (and you have a legitimate interest in Alfresco and our products, authorizing us to contact you in such methods). If you are not ok with these terms, please do not use this website.