Closed kastoras closed 5 years ago
Hi @kastoras,
Can you show me the complete error trace of the datatable response?
Hi @kastoras,
I reproduced the problem. The package can't handle 2 or more tables at onces. In the next version update the issue will be fixed.
Ok thank you, if i will find a solution i will let you know.
issue is fixed in #15 see the changes.
The problem is with the Facade. It overwrites the tables. You can use multiple tables by directly calling the package controller.
use SingleQuote\DataTables\DataTable;
$companytable =(new DataTable)->model(\App\Company::class)->tableModel(\App\TableModels\Companies::class);
$producttable = (new DataTable)->model(\App\Product::class)->tableModel(\App\TableModels\Products::class);
Hello,
I have problem when i try to have two datatables in the same Page.
Initialise datatables:
Send to view:
return view('view_file',[ ])->with(compact('companytable','producttable'));
Try to use them on view file:
With this code i get Datatables error:
Is it possible to do something like this or i can have only one datatable per page;
Thanks in advance.