CRUD
CRUD copied to clipboard
Add List order support for translatable models
WHY
BEFORE - What was wrong? What was happening before this PR?
This is a redo of #4176 . Thanks @guleswine for the contribution, I merged your PR here but needed to re-factor it cause the structure of ListOperation changed.
TLDR: Translatable fields are not orderable in ListOperation.
AFTER - What is happening after this PR?
Checking if column is JSON, if it is, we can safelly apply the JSON->order synthax.
Is it a breaking change?
I don't think so, no.
How can we test the before & after?
Try to order the name column in the Products controller.
Hi @pxpm i try to reproduce this error but i cant.
Product table on demo have name, description and others as json field type on database (mysql)

I go to list view and try to reorder, everything works i try in "main" branch

Do i miss something?
Cheers.
Hey @jorgetwgroup I don't think A->M->T->A (the initials on the name column) are ordered ... 🙃
Cheers
Hi @pxpm
OMG, in my defense, im very good with numbers, but now i discovery my weakness (letters) 😢
I check this with main branch

Then with pr/4176 branch

Everything work great!
For me look ready, but i understand is needed to sync with https://github.com/Laravel-Backpack/CRUD/pull/4649
@tabacitu is in your hands now
Cheers.