Row Data in Advanced Datatables ( master details )
Row Data in Advanced Datatables ( master details )
I am trying to create advanced datatables like the example # 2 in this https://quickadminpanel.com/blog/advanced-datatables-with-laravel-five-code-examples/
and my code is same as what they did , using ajax in this codehttps://github.com/LaravelDaily/Laravel-Datatables-Advanced/blob/master/resources/views/customers/master_details.blade.php
so i have now master table and inside each row there is details table
and i added action in master rows
its work perfect but when i want to add action to every row in the details table I cant get row data
any idea ?
Answers
Without seeing what you are doing its hard to say but my guess is you need to use delegated events as described in this FAQ:
https://datatables.net/faqs/index#events
Or you can initialize the events in the
initComplete
option of the child table. You might want to make sure to use.off()
first to make sure you don't create multiple events for the same child.Kevin