2017 © Pedro Peláez
 

library datatables

Create HTTP responses compatible with Datatables for JQuery from Eloquent Models, Query Builders, and Laravel Collections.

image

markese/datatables

Create HTTP responses compatible with Datatables for JQuery from Eloquent Models, Query Builders, and Laravel Collections.

  • Friday, August 25, 2017
  • by jmarkese
  • Repository
  • 1 Watchers
  • 4 Stars
  • 11 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 2 Forks
  • 0 Open issues
  • 4 Versions
  • 10 % Grown

The README.md

Datatables for Laravel

![Software License][ico-license], (*1)

A package for Laravel that integrates Eloquent queries and Illuminate Collections into Datatables for JQuery., (*2)

Structure

src/

Install

Via Composer, (*3)

``` bash $ composer require markese/datatables, (*4)


## Usage ``` php // Laravel: namespace App\Http\Controllers; use Markese\Datatables\Datatables; class Controller extends BaseController { public function datatablesExample (Request $request) { $users = Users::query(); return Datatables::response($users, $request); } }

``` javascript // Datatables: $('#example').DataTable( { "serverSide": true, "processing": true, "ajax": "datatablesexample", columns : [ // The "name" property in the column initialization for Model attributes are optional., (*5)

    // This works...
    { "data": "id", "title": "Id" },

    // And so does this...
    { "data": "name", "title": "Name", "name": "name" },
    { "data": "email", "title": "Number", "name": "email" },

    // The "name" properties in your Datatables column initialization
    // will eager load the relations of the Model you are querying against 
    // when you use Laravel dot notation...
    { "data": "groups[].name", "title": "Groups", "name": "groups.*.name" },

    // The "data" properties in the column initialization represent the displayed data
    // which is accessible using standard JavaScript bracket notation...
    { "data": "groups[].roles[].title", "title": "Roles", "name": "groups.*.roles.*.title" }
]

} ); ```, (*6)

Change log

Please see CHANGELOG for more information on what has changed recently., (*7)

Contributing

Please see CONTRIBUTING and CONDUCT for details., (*8)

Security

If you discover any security related issues, please email john.markese@gmail.com instead of using the issue tracker., (*9)

Credits

License

The MIT License (MIT). Please see License File for more information., (*10)

The Versions

25/08 2017

dev-master

9999999-dev https://github.com/jmarkese/Datatables

Create HTTP responses compatible with Datatables for JQuery from Eloquent Models, Query Builders, and Laravel Collections.

  Sources   Download

MIT

The Requires

 

The Development Requires

datatables markese

21/03 2017

1.0.1

1.0.1.0 https://github.com/jmarkese/Datatables

Create HTTP responses compatible with Datatables for JQuery from Eloquent Models, Query Builders, and Laravel Collections.

  Sources   Download

MIT

The Requires

 

The Development Requires

datatables markese

21/03 2017

dev-strategies_for_eloquent_and_queries

dev-strategies_for_eloquent_and_queries https://github.com/jmarkese/Datatables

Create HTTP responses compatible with Datatables for JQuery from Eloquent Models, Query Builders, and Laravel Collections.

  Sources   Download

MIT

The Requires

 

The Development Requires

datatables markese

12/03 2017

1.0.0

1.0.0.0 https://github.com/jmarkese/Datatables

Create HTTP responses compatible with Datatables for JQuery from Eloquent Models, Query Builders, and Laravel Collections.

  Sources   Download

MIT

The Requires

 

The Development Requires

datatables markese