Here are all the functions you will be using inside your EntityCrudController's setup() method, grouped by the operation you will most likely use them for.




Manipulate what columns are shown in the table view.

  • addColumn() - add a column, at the end of the stack

  • addColumns() - add multiple columns, at the end of the stack

    $this->crud->addColumns([$column_definition_array, $another_column_definition_array]); 
  • modifyColumn() - change column attributes

    $this->crud->modifyColumn($name, $modifs_array);
  • removeColumn() - remove one column from all operations

  • removeColumns() - remove multiple columns from all operations

    $this->crud->removeColumns(['column_name_1', 'column_name_2']); // remove an array of columns from the stack
  • setColumnDetails() - change the attributes of one column; alias of modifyColumn();

    $this->crud->setColumnDetails('column_name', ['attribute' => 'value']);
  • setColumnsDetails() - change the attributes of multiple columns; alias of modifyColumn();

    $this->crud->setColumnsDetails(['column_1', 'column_2'], ['attribute' => 'value']);
  • setColumns() - remove previously set columns and only use the ones give now;

    // sets the columns you want in the table view, either as array of column names, or multidimensional array with all columns detailed with their types
  • Chained - beforeColumn() - insert current column before the given column

    // ------ REORDER COLUMNS
  • Chained - afterColumn() - insert current column after the given column

  • Chained - makeFirstColumn() - make this column the first one in the list

    // Please note: you need to also specify priority 1 in your addColumn statement for details_row or responsive expand buttons to show


  • addButton() - add a button in the given stack

    $this->crud->addButton($stack, $name, $type, $content, $position); 
    // stacks: top, line, bottom
    // types: view, model_function
    // positions: beginning, end (defaults to 'beginning' for the 'line' stack, 'end' for the others);
  • addButtonFromModelFunction() - add a button whose HTML is returned by a method in the CRUD model

    $this->crud->addButtonFromModelFunction($stack, $name, $model_function_name, $position);
  • addButtonFromView() - add a button whose HTML is in a view placed at resources\views\vendor\backpack\crud\buttons

    $this->crud->addButtonFromView($stack, $name, $view, $position);
  • removeButton() - remove a button from whatever stack it's in

  • removeButtonFromStack() - remove a button from a particular stack

    $this->crud->removeButtonFromStack($name, $stack);


Manipulate what filters are shown in the table view. Check out CRUD > Operations > ListEntries > Filters to see examples of $filter_definition_array

  • addFilter() - add a filter to the list view

    $this->crud->addFilter($filter_definition_array, $values, $filter_logic);
  • modifyFilter() - change the attributes of a filter

    $this->crud->modifyFilter($name, $modifs_array);
  • removeFilter() - remove a certain filter from the list view

  • removeAllFilters() - remove all filters from the list view

  • filters() - get all the registered filters for the list view


Details Row

Shows a + (plus sign) next to each table row, so that the user can expand that row and reveal details. You are responsible for creating the view with those details.

  • enableDetailsRow() - show the + sign in the table view

    // NOTE: you also need to do allow access to the right users:
    // NOTE: you also need to do overwrite the showDetailsRow($id) method in your EntityCrudController to show whatever you'd like in the details row OR overwrite the views/backpack/crud/details_row.blade.php
  • disableDetailsRow() - hide the + sign in the table view


Export Buttons

Please note it will only export the current page of results. So in order to export all entries the user needs to make the current page show "All" entries from the top-left picker.

  • enableExportButtons() - Show export to PDF, CSV, XLS and Print buttons on the table view

Responsive Table

  • disableResponsiveTable() - stop the listEntries view from showing/hiding columns depending on viewport width

  • enableResponsiveTable() - make the listEntries view show/hide columns depending on viewport width


Persistent Table

  • enablePersistentTable() - make the listEntries remember the filters, search and pagination for a user, even if he leaves the page, for 2 hours

  • disablePersistentTable() - stop the listEntries from remembering the filters, search and pagination for a user, even if he leaves the page


Page Length

  • setDefaultPageLength() - change the number of items per page in the list view

  • setPageLengthMenu() - change the entire page length menu in the list view

    $this->crud->setPageLengthMenu([100, 200, 300]);

Actions Column

  • setActionsColumnPriority() - make the actions column (in the table view) hide when not enough space is available, by giving it an unreasonable priority

Custom / Advanced Queries

  • addClause() - change what entries are shown in the table view; this allows developers to forcibly change the query used by the table view, as opposed to filters, that allow users to change the query with new inputs;

    $this->crud->addClause('active'); // apply local scope
    $this->crud->addClause('type', 'car'); // apply local dynamic scope
    $this->crud->addClause('where', 'name', '=', 'car');
    $this->crud->addClause('whereName', 'car');
    $this->crud->addClause('whereHas', 'posts', function($query) {
  • groupBy() - shorthand to add a groupBy clause to the query

  • limit() - shorthand to add a limit clause to the query

  • orderBy() - shorthand to add an orderBy clause to the query



Use the same Columns API as for the ListEntries operation, but inside your show() method.

Create & Update Operations

Manipulate what fields are shown in the create / update forms. Check out CRUD > Operations > Create & Update > Fields in the docs to see examples of $field_definition_array.

Note: The last parameter is always the form - create or update. If missing, it's assumed both.

  • addField() - add one field to the create / update or both forms

    $this->crud->addField($field_definition_array, 'update/create/both');
    $this->crud->addField('db_column_name', 'update/create/both'); // a lazy way to add fields: let the CRUD decide what field type it is and set it automatically, along with the field label
  • addFields() - add multiple fields to the create / update or both forms

    $this->crud->addFields($array_of_fields_definition_arrays, 'update/create/both');
  • modifyField() - change the attributes of an existing field

    $this->crud->modifyField($name, $modifs_array, 'update/create/both');
  • removeField() - remove a given field from a given operation

    $this->crud->removeField('name', 'update/create/both');
  • removeFields() - remove multiple fields from a given operation

    $this->crud->removeFields($array_of_names, 'update/create/both');
  • removeAllFields() - remove all registered fields from both create and update operations

  • Chained - beforeField() - add a field before a given field

  • Chained - afterField() - add a field after a given field

  • setRequiredFields() - check the FormRequests used in this EntityCrudController for required fields, and add an asterisk to them in the create or edit forms

    $this->crud->setRequiredFields(StoreRequest::class, 'create');
    $this->crud->setRequiredFields(UpdateRequest::class, 'edit');


Show a reorder button in the table view, next to Add. Provides an interface to reorder & nest elements, provided the parent_id, lft, rgt, depth columns are in the database, and $fillable on the model.

  • enableReorder() - enable the Reorder functionality

    $this->crud->enableReorder('label_name', 3);
    // NOTE: the second parameter is the maximum nesting depth; this example will prevent the user from creating trees deeper than 3 levels;
    // NOTE: you also need to do allow access to the right users:
  • disableReorder() - disable the Reorder functionality

  • isReorderEnabled() - returns true/false if the Reorder operation is enabled or not



A.k.a. Audit Trail. Tracks all changes to an entry and provides an interface to revert to a previous state. In order to use this, you also need to use \Venturecraft\Revisionable\RevisionableTrait;. Please check out the Revision Operation for more info.


All Operations


Prevent or allow users from accessing different CRUD operations.

  • allowAccess() - give users access to one or multiple operations

    $this->crud->allowAccess(['list', 'create', 'delete']);
  • denyAccess() - prevent users from accessing one or multiple operations

    $this->crud->denyAccess(['list', 'create', 'delete']);
  • hasAccess() - check if the current user has access to one or multiple operations

    $this->crud->hasAccess('add'); // returns true/false
    $this->crud->hasAccessOrFail('add'); // throws 403 error
    $this->crud->hasAccessToAll(['create', 'update']); // returns true/false
    $this->crud->hasAccessToAny(['create', 'update']); // returns true/false

Eager Loading Relationships

  • with() - when the current entry is loaded (in any operation) also get its relationships, so that only one query is made to the database per entry

Custom Views

  • setShowView(), setEditView(), setCreateView(), setListView(), setReorderView(), setRevisionsView(), setRevisionsTimelineView(), setDetailsRowView() - set the view for a certain CRUD operation or feature
    // use a custom view for a CRUD operation


  • getEntry() - get a certain entry of the current model type

  • getEntries() - get all entries using the current CRUD query

  • getFields() - get all fields for a certain operation, or for both

  • getCurrentEntry() - get the current entry, for operations that work on a single entry

    // ex: in your update() method, after calling parent::updateCrud()


  • getOperation() - get the name of the operation that is currently being performed

  • setOperation() - set the name of the operation that is currently being performed



An action is the controller method that is currently being run.

  • getActionMethod() - returns the method on the controller that was called by the route; ex: create(), update(), edit() etc;

  • actionIs() - checks if the given controller method is the one called by the route


Title, Heading, Subheading

  • getTitle() - get the Title for the create action

  • getHeading() - get the Heading for the create action

  • getSubheading() - get the Subheading for the create action

  • setTitle() - set the Title for the create action

    $this->crud->setTitle('some string', 'create');
  • setHeading() - set the Heading for the create action

    $this->crud->setHeading('some string', 'create');
  • setSubheading() - set the Subheading for the create action

    $this->crud->setSubheading('some string', 'create');

CrudPanel Basic Info

  • setModel() - set the Eloquent object that should be used for all operations

  • setRoute() - set the main route to this CRUD

    // OR $this->crud->setRouteName("admin.example");
  • setEntityNameStrings() - set how the entity name should be shown to the user, in singular and in plural

    $this->crud->setEntityNameStrings("example", "examples");

Like our open-core?

Then you'll love our premium add-ons - productivity tools and tons of new features.