Download the PHP package anik/laravel-backpack-extension without Composer

On this page you can find all versions of the php package anik/laravel-backpack-extension. 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-backpack-extension

anik/laravel-backpack-extension codecov

In the table view of backpack/crud list operation, if a column exists in database table, it's by default searchable and orderable unless instructed otherwise. Also, to add a column or field to the operation, it is required to pass an array. In PHP, array keys are case-sensitive and this make it tedious when adding a field or column. This package allows class based imperative approach over passing the array. So no more tedious, repetitive typing game matching the exact array keys. BE FORGETFUL sometimes? 🤷

Documentation

Installation

To install the package, run

composer require anik/laravel-backpack-extension

Usage

Extending controller

Instead of extending the \Backpack\CRUD\app\Http\Controllers\CrudController, use \Anik\LaravelBackpack\Extension\Controllers\CrudController in your controllers.


Adding Column

To instantiate a Column

To add the column(s) from the controller

By default, all Column instances are not orderable and not searchable.

Example

Available methods

Note

Column class uses \Anik\LaravelBackpack\Extension\Extensions\Attributable trait. Check Attributable section.


Adding Field

To instantiate a Field

Or to create an OptionalField

To add the field(s) from the controller

By default, all the Field instances are required.

Example

Available methods

Note

Field class uses \Anik\LaravelBackpack\Extension\Extensions\Attributable trait. Check Attributable section.


Adding Filter

To instantiate a Filter

To add the filters(s) from the controller

Example

Available methods

Note

Filter class uses \Anik\LaravelBackpack\Extension\Extensions\Attributable trait. Check Attributable section.


Adding Widget

To instantiate a Widget

To add the widget(s) from the controller

Example

Available methods

Note

Widget class uses \Anik\LaravelBackpack\Extension\Extensions\Attributable trait. Check Attributable section.


Relation

If a Column or Field points to an Eloquent relationship, then you can use Anik\LaravelBackpack\Extension\Relations\Relation.

To instantiate a Relation

Parameters:

The package provides 4 relations out-of-the-box which uses the type suggested by Backpack.

If you want a customized Relationship, you can use \Anik\LaravelBackpack\Extension\Relations\CustomRelation.

Example

Available methods

Note

Only CustomRelation class uses \Anik\LaravelBackpack\Extension\Extensions\Attributable trait. Check Attributable section.


Attributable trait

The Attributable trait allows classes to save and retrieve attributes in array format. Classes that use the trait will have access to the following methods.

Example


All versions of laravel-backpack-extension with dependencies

PHP Build Version
Package Version
Requires php Version ^8.0
backpack/crud Version ^5.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 anik/laravel-backpack-extension contains the following files

Loading the files please wait ....