for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
We could not synchronize checks via GitHub's checks API since Scrutinizer's GitHub App is not installed for this repository.
Install GitHub App
<?php
namespace Backpack\MenuCRUD\app\Http\Controllers\Admin;
use Backpack\CRUD\app\Http\Controllers\CrudController;
class MenuItemCrudController extends CrudController
{
use \Backpack\CRUD\app\Http\Controllers\Operations\ListOperation;
use \Backpack\CRUD\app\Http\Controllers\Operations\CreateOperation;
use \Backpack\CRUD\app\Http\Controllers\Operations\UpdateOperation;
use \Backpack\CRUD\app\Http\Controllers\Operations\DeleteOperation;
use \Backpack\CRUD\app\Http\Controllers\Operations\ReorderOperation;
public function setup()
$this->crud->setModel("Backpack\MenuCRUD\app\Models\MenuItem");
$this->crud->setRoute(config('backpack.base.route_prefix').'/menu-item');
$this->crud->setEntityNameStrings('menu item', 'menu items');
$this->crud->enableReorder('name', 3);
$this->crud->operation('list', function () {
operation()
Backpack\CRUD\CrudPanel
doingListOperation()
This check marks calls to methods that do not seem to exist on an object.
This is most likely the result of a method being renamed without all references to it being renamed likewise.
$this->crud->addColumn([
'name' => 'name',
'label' => 'Label',
]);
'label' => 'Parent',
'type' => 'select',
'name' => 'parent_id',
'entity' => 'parent',
'attribute' => 'name',
'model' => "\Backpack\MenuCRUD\app\Models\MenuItem",
});
$this->crud->operation(['create', 'update'], function () {
$this->crud->addField([
'name' => 'type',
'label' => 'Type',
'type' => 'page_or_link',
'page_model' => '\Backpack\PageManager\app\Models\Page',
}
This check marks calls to methods that do not seem to exist on an object.
This is most likely the result of a method being renamed without all references to it being renamed likewise.