Hi,
How the sort icon of a column header can be clicked programmatically?
Thanks!
Support Forum
Thanks.
- I'm defining a custom sorter for the 'startDate' column.
- When i click on the sort icon the custom sorter is called and everything works well.
- When i call to store.sort('startDate') my custom sorter is not called and the sorting is wrong..
- If a call store.sort(myfuncion) with my custom sorting function the sorting works but the sort icon on the column doesn't remain pressed so the sorting is lost when the filtering is changed. That's why i'm trying to click the sorting icon button programmatically because when i click it by hand all works as i need.
¿Any tip?
- I'm defining a custom sorter for the 'startDate' column.
- When i click on the sort icon the custom sorter is called and everything works well.
- When i call to store.sort('startDate') my custom sorter is not called and the sorting is wrong..
- If a call store.sort(myfuncion) with my custom sorting function the sorting works but the sort icon on the column doesn't remain pressed so the sorting is lost when the filtering is changed. That's why i'm trying to click the sorting icon button programmatically because when i click it by hand all works as i need.
¿Any tip?
I mean that if in the column config you provide a custom sorting function in the sortable property this function is called when you click on the sort icon of the header but is not called when you call it by code: store.sort('foo')
https://bryntum.com/docs/scheduler/#Grid/column/Column#config-sortable
https://bryntum.com/docs/scheduler/#Grid/column/Column#config-sortable
Thanks. I now understand that this sort call has nothing to do with the Column. So.. can i click the sort icon of the column programmatically? I need the icon visual pressed status and the sorting to remain between filtering changes. From a user point of view i need not having to press the sort icon to get the sorting the first time the grid is presented to the user. I need to sort one concrete column by default as when i click the sort icon but not having to.