MedicOneSystems / livewire-datatables

Advanced datatables using Laravel, Livewire, Tailwind CSS and Alpine JS
https://livewire-datatables.com/
MIT License
1.19k stars 258 forks source link

Cant use editable() with laravel 9 #438

Open Renaud404 opened 2 years ago

Renaud404 commented 2 years ago

Hello,

When i make a column ->editable() since i did an upgrade to laravel 9 and datatables to 0.7.0 (or 0.8) i have this message :

Undefined variable $table

If i remove editable(), everthing works great,

I also tried the lastest 0.9.3, but i cant make a table works on this version (editable or not), juste a message : Undefined array key "align"

Any solution ? Do i have to change something in my code for newer version ?

shaneburrell commented 2 years ago

I'm using laravel 9 with no issue. Have you updated your composer and packages?

Renaud404 commented 2 years ago

yep, but i use custom column with scope, action etc extensively, i dont got any problem on simple table.

EricPaulson commented 2 years ago

I ran into the same issue, and to be honest, I'm surprised editable columns are working at all. If you look at the source code, you can see that the 'table' variable is not being passed into the editable view, hence it's undefined.

nileshd commented 1 year ago

I am having the same issue - Undefined variable $table

I am using PHP 8.2.0 and Laravel 9.52.7

I was having the error on livewire-datatables 0.9.5 and the error was happening. I upgraded to 0.10.1 and the same error is still happening.

nileshd commented 1 year ago

Ah.. i was able to solve it.. I had initially published the vendor assets to my views from the older version and did not republish with newer version.. after republishing the view assets, it works fine.