laravel-datatables
laravel-datatables copied to clipboard
Method Illuminate\Http\JsonResponse::toJson does not exist.
Laravel 5.7 laravel-datatables 8.0
When using datatables as a service the ajax function gives this error
Cloned the ajax() function into my QuoteDataTable class and replaced return $dataTable->toJson(); with return $dataTable; which seems to have worked.
I tried following all the docs for this but I'm not sure if the docs are wrong or the package is not fully compatible with L5.7?
Nah, you might be running into a different issue. Im using Laravel 5.7 and works just fine, why you dont use instead datatable()->eloquent() ?
Tried that but same issue. I'm wondering if it's something to do with the upgrade from 6.0 also upgraded Laravel from 5.4 at same time so it light even be a Laravel thing
@igerslike Are you using datatables as a service?
Yes, just followed the tutorial and worked just fine. Try doing a clean install of Laravel and check if it works, you probably running into some other issue. @quantumwebco
I get the same issue any solution, The GET method is added in form and in route
This issue is stale because it has been open for 30 days with no activity. Remove stale label or comment or this will be closed in 7 days.
This issue was closed because it has been inactive for 7 days since being marked as stale.