Can't reorder table rows
When trying to reorder table rows in a
RelationManager
values in order_column
DB do change but the rows are always jumping back to their initial position. I've activated reordering on the table like that:
Here's a short screen capture:5 Replies
Can I see your model.php? are you trying use eloquent-sortable package?
GitHub
GitHub - spatie/eloquent-sortable: Sortable behaviour for Eloquent ...
Sortable behaviour for Eloquent models. Contribute to spatie/eloquent-sortable development by creating an account on GitHub.
Yeah, I'm using this package and my model looks like that:
That seems ok. Is the name of your column really 'order_column' or was it something else?
Mine works well with this:
resource
model
Yes, the name is
order_column
and as already mentioned it does change in the DB when reordering.
Did you also have this in a RelationManager
?