yajra / laravel-datatables-scout
Laravel DataTables Scout Plugin.
dev-master / 1.0.x-dev
2017-07-20 01:35 UTC
Requires
- php: >=7.0
- laravel/scout: ^3.0
- yajra/laravel-datatables-oracle: 8.*
Requires (Dev)
- orchestra/testbench: ~3.5
This package is auto-updated.
Last update: 2024-11-08 17:58:49 UTC
README
This package is a plugin of Laravel DataTables to support searching using Laravel Scout.
Requirements
Documentations
Installation
composer require yajra/laravel-datatables-scout:^1.0
Usage
Use the dataTable class directly.
use Yajra\DataTables\ScoutDataTable; $model = new App\User; return (new ScoutDataTable($model))->toJson()
Use via trait.
- You need to use
ScoutDataTable
trait on your model.
use Yajra\DataTables\Traits\ScoutDataTable; class User extends Model { use ScoutDataTable; }
- Process dataTable directly from your model.
Route::get('users/data', function() { return User::dataTable()->toJson(); });
Contributing
Please see CONTRIBUTING for details.
Security
If you discover any security related issues, please email aqangeles@gmail.com instead of using the issue tracker.
Credits
License
The MIT License (MIT). Please see License File for more information.