Download the PHP package devchithu/laravel-filter-sorting-searchable without Composer

On this page you can find all versions of the php package devchithu/laravel-filter-sorting-searchable. 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-filter-sorting-searchable

laravel Devchithu-Filter-Sorting-Searchable

Latest Stable Version Total Downloads Latest Unstable Version License PHP Version Require

This Package for handling dynamic column sorting, filter and searchable in Laravel.

Installation & Usages

Basic Setup

Install via composer; in console:

or require in composer.json:

then run composer update in your terminal to pull it in.

Once this has finished, you will need to add the service provider to the providers array in your app.php config as follows:

path : project/config/app.php

Find 'providers=>[]' add inside below code (Custom Service Providers...)

Example like code : project/config/app.php

Usages

Use FilterSortSearchable trait inside your Eloquent model(s).

Font Awesome 6.4^ (default font classes)

Install Font-Awesome Search "sort" in cheatsheet and see used icons yourself.

Completed.

Bootstrap 5 version

CSS File

JS File

Publish Js file

then run publish cmd you must to publish only js file and where-ever your want 'filter, sort, searchable' using the below script in blade.php file

See public/filter-sorting-searchable.js (if you want any change update this code inside)

Two method of design filter sorting extension

1. Bootstrap Inline filter sorting Blade Extension

2. Bootstrap filter using Modal, Offcanvas Blade Extension

Two Type of blade extension using script file.

1. Bootstrap Inline filter sorting Blade Extension

Must push that js file in blade, where-ever your want like (better than push that js file into main index blade.php):

OR,

* Sorting

There is a blade extension for you to use @filterSort()

Custom field name sorting

Here,

  1. sorting parameter default is false. true is sorting enabled, if don't need sorting just put false or just remove sorting parames.
  2. field_name parameter is column in database table field, name.
  3. label_name parameter is displayed inside anchor tags and print valueable field name. incase of label_name doe'st use automatically get column in database table field.

what are field sorting declare the using your Eloquent model(s) inside function like below code,

Use FilterSortSearchable trait inside your Eloquent model(s).

Eloquent model

Controller's index() method

* Inline Filter

Blade table config

There is a sorting similar same blade extension for you to use @filterSort()

Custom field name filter

what are field filterable declare the using your Eloquent model(s) inside function like below code,

Controller's index() method

Sorting & Filter

Incase, If you want sort and filter sametime using below Code,

Here,

  1. filter parameter default is false. true is filter enabled, if don't need filter just put false or just remove filter parames.
  2. field_name parameter is column in database table field, name.
  3. label_name parameter is displayed inside anchor tags and print valueable field name. incase of label_name doe'st use automatically get column in database table field.

UI - filter input field automatically generate

  1. filter is true default create input box type = 'text', if you want different input type like (selelect, radio, range) below code put the array params 'type' => 'text' // 'type' => 'select' or radio, range

Here, if you select option using multiple option value data like `'multiple_option' => ['All', 'active', 'in_active']

what are field sorting and filter declare the using your Eloquent model(s) inside function like below code,

Controller's index() method

Controller's index() method with paginate()

*Searchable

This searchable global area find the table data

what are field searchable declare the using your Eloquent model(s) inside function like below code,

There is a blade extension for you to use @searchable()

Controller's index() method

Controller's index() method

If you want filter, sorting, searchable declare the scope function

*customized filter

If you want filter some field customazed used here file

See app\CustomFilter\CustomFilterTrait.php (if you want any change update this code inside)

what are the customized filter field don't declare (filterable) array. declare custom filterable the using your Eloquent model(s) inside function,

* Binding Params

What are field sorting, searching and filterting below code Which place to you want binding parameters declare the @bindingParams()

Run finally,

OR,

2. Bootstrap filter using Modal, Offcanvas Blade Extension

Publish Js file

then run publish cmd you must to publish only js file your want 'filter, sort, searchable' using the below script in blade.php file

See public/filter-sorting-searchable-modal-offcanvas.js (if you want any change update this code inside)

Must push that js file in blade, where-ever your want like (better than push that js file into main index blade.php):

OR,

Sorting & Filter

Incase, If you want sort and filter sametime using below Code,

Modal Offcanvas Filter

Filter Button show below code in blade: Whereever you want filter button put the code @filterBtn()

Default Offcanvas

Here, Bootstrap5^ default offcanvas inside.

Change Custom name

when, if you need button label name change parse the parameter like

Bootstrap5^ Offcanvas and Modal

Default offcanvas don't need any params, if need to change modal window like code :

Bootstrap5 Modal

Here

  1. viewport is default offcanvas if change modal given in array inside
  2. if viewport_direction is offcanvas placement direction (like: offcanvas-start, offcanvas-end, offcanvas-top, offcanvas-bottom)
  3. if viewport_direction is modal placement modal-dialog-position (like: modal-dialog-centered, modal-size-(xl)*)

Run finally,

Don't declare at the sametime two type of js file, at time only one using js file

(filter-sorting-searchable.js Or filter-sorting-searchable-modal-offcanvas.js)

Thank you .


All versions of laravel-filter-sorting-searchable with dependencies

PHP Build Version
Package Version
Requires php Version ^7.2|^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 devchithu/laravel-filter-sorting-searchable contains the following files

Loading the files please wait ....