underwear / laravel-vue-good-table

Vue-good-table wrapper for Laravel. Server side tables without pain.
MIT License
41 stars 13 forks source link

BUG: Click to sort third time on heading sets the sort type to none which causes a 500 server error #6

Closed jgulledge19 closed 2 years ago

jgulledge19 commented 3 years ago

I have set up a simple controller and page with just 4 columns, ID, first_name, last_name and email. They are all sortable columns. My sample data has about 5,000 rows. When I click on any column heading for the 3rd time it sends a parameter value for sort type that causes a 500 server error.

Click one URL: ../clients/table/data?sort[type]=asc&sort[field]=email&page=1&perPage=30&q= Click two URL: ../clients/table/data?sort[type]=desc&sort[field]=email&page=1&perPage=30&q= Third click: ../clients/table/data?sort[type]=none&sort[field]=email&page=1&perPage=30&q=

The sort[type]=none is what breaks the API request.