Download the PHP package dykhuizen/laravel-datatable without Composer

On this page you can find all versions of the php package dykhuizen/laravel-datatable. It is possible to download/install these versions without Composer. Possible dependencies are resolved automatically.

FAQ

After the download, you have to make one include require_once('vendor/autoload.php');. After that you have to import the classes with use statements.

Example:
If you use only one package a project is not needed. But if you use more then one package, without a project it is not possible to import the classes with use statements.

In general, it is recommended to use always a project to download your libraries. In an application normally there is more than one library needed.
Some PHP packages are not free to download and because of that hosted in private repositories. In this case some credentials are needed to access such packages. Please use the auth.json textarea to insert credentials, if a package is coming from a private repository. You can look here for more information.

  • Some hosting areas are not accessible by a terminal or SSH. Then it is not possible to use Composer.
  • To use Composer is sometimes complicated. Especially for beginners.
  • Composer needs much resources. Sometimes they are not available on a simple webspace.
  • If you are using private repositories you don't need to share your credentials. You can set up everything on our site and then you provide a simple download link to your team member.
  • Simplify your Composer build process. Use our own command line tool to download the vendor folder as binary. This makes your build process faster and you don't need to expose your credentials for private repositories.
Please rate this library. Is it a good library?

Informations about the package laravel-datatable

Datatable Laravel 7+

Package for converting a request into a datatable response with searching, sorting, filtering, pagination, and data minimization in Laravel 7+.

Setup

Composer

Pull this package in through Composer

Usage

Use Datatable trait inside your Eloquent model(s). This single trait gives you access the following traits:

Sortable

The sortable columns and order default to the keys sortColumns and sortOrder respectively.
These keys can be overwritten on a per model instance by setting the $sortableColumnsKey and $sortableOrderKey variables.
The values are expected to be comma delimited values and work with HasOne and BelongsTo relations

Ex:

If you wish to have a field ordered which does not exist within a model's fields, you can optionally define a [property]Sortable function
Below is an address example

Searchable

The searchable columns and search default to the keys searchColumns and search respectively.
These keys can be overwritten on a per model instance by setting the $searchableColumnsKey and $searchableSearchKey variables.
The values are expected to be comma delimited values and work with any type of relation

Ex:

If you wish to have a field searched which does not exist within a model's fields, you can optionally define a [property]Searchable function
Below is an address example

Filterable

The filterable column defaults to the key filter
This key can be overwritten on a per model instance by setting the $filterableFieldsKey variable.
The values are expected to be comma delimited values and work with any type of relation Additionally, the filter values are expected to be passed as unique fields. For example, filter on status expends the keys filter = status and filter_status = 'yes,no,maybe to exist

Ex:

If you wish to have a field filtered which does not exist within a model's fields or has a unique filter attribute, you can optionally define a [property]Filterable function
Below is an address example

Paginateable and SimplePaginateable

The paginateable columns default to page and per_page just like Laravel's built in pagination
These keys can be overwritten on a per model instance by setting the $paginateablePageKey and $paginateablePerPageKey variables.
If these keys exist, results will be paginated in the response. If these keys do not exist, the $forcePagination function param will be checked. If true, results will be paginated according to Laravel defaults. If false, results will be retrieved via the get() method.

Ex:

Selectable

The selectable column defaults to selectableFields
This key can be overwritten on a per model instance by setting the $selectableFieldsKey variable
If this field exists, the selectable function will set a static property with these fields to be masked down to upon the call to toArray()
The goal of this trait is to reduce the response size when returning data to a front end application
For security reasons, the relation depth is maxed at 3 and if a relation is not loaded into the model before toArray() is called selectable will abort() out as someone is attempting to load relations dynamically which could cause data leakage

Ex:


All versions of laravel-datatable with dependencies

PHP Build Version
Package Version
Requires php Version ^7.3 | ^8.0
illuminate/database Version ^7.0 | ^8.0
illuminate/support Version ^7.0 | ^8.0
Composer command for our command line client (download client) This client runs in each environment. You don't need a specific PHP version etc. The first 20 API calls are free. Standard composer command

The package dykhuizen/laravel-datatable contains the following files

Loading the files please wait ....