packagist yajra/laravel-datatables-oracle v5.11.0
Add support for rendering view

latest releases: dev-master, dev-yajra-patch-1, dev-analysis-6VeDmM...
9 years ago

addColumn and editColumn will now load view if it exists. All eloquent/data attributes will be passed as variables on view.

Usage:

Controller

return $datatables
    ->eloquent($builder)
    ->addColumn('action', 'admin.users.datatables.action')
    ->editColumn('active', 'admin.users.datatables.active')

View
/resources/views/admin/users/datatables/action.blade.php

{{ $first_name }} #{{ $id }}

/resources/views/admin/users/datatables/active.blade.php

@if($active)
active
@else
inactive
@endif

Don't miss a new laravel-datatables-oracle release

NewReleases is sending notifications on new releases.