Grid Sorting

#1

I have a strange issue where I have a grid of data. The data is sorted by default on "created desc". I also have a LoadData sort on the grid iteself of "${event.orderby || 'Created desc' } . This should give me a default sort of the newest items by created date with the option for the user to change it to another column. It also appears that it works until you look for a record that you know should be there at the top but isn't. When I manually sort by date it switches to oldest first and then when I click back to newest first all of the records are correctly sorted and I can see the missing records at the top, since they are relatively new. What would cause this? I've attached some screenshots showing this.



Josh

0 Likes

#2

Can you check what the server response is in the Network dev tools tab? Then there is a Preview subtab that shows what the server returned as an expandable tree. The DataGrid should display what the server has returned. Just in case make sure the initial sorting in the Page Load event is the same as the one in the LoadData event of the grid (ideally you can just Execute this.grid0.load() during Page Load so it immediatelly triggers the LoadData event of the DataGrid with Name set to grid0).

0 Likes

#3

Thanks. I will try just executing the this.grid0.load() and see how it goes.

Josh

0 Likes