I am using this gem API to build a datatable endpoint on graphql. While testing some things I saw that this was not working:
::Chat::IndexGrid.new(order: "name", descending: false).data_hash
It was not ordered. Then I started to debug, I notice the condition on lib/datagrid/columns.rb:490, when using the batch each it is not considered the order of the asset. I can debug more later, but for now, thats what I have.
A workaround is set self.batch_size = 0.
I am using this gem API to build a datatable endpoint on graphql. While testing some things I saw that this was not working:
::Chat::IndexGrid.new(order: "name", descending: false).data_hash
It was not ordered. Then I started to debug, I notice the condition on lib/datagrid/columns.rb:490, when using the batch each it is not considered the order of the asset. I can debug more later, but for now, thats what I have.
A workaround is set self.batch_size = 0.