wbe/crud

There is no license information available for the latest version (2.3.8) of this package.

Admin panel with CRUD generator, based on Rapyd

Installs: 440

Dependents: 0

Suggesters: 0

Security: 0

Stars: 2

Watchers: 2

Forks: 1

Open Issues: 0

Language:HTML

Type:project

2.3.8 2018-01-12 08:15 UTC

README

Install in Laravel 5.5

  1. Config. Replace into config/database.php: 'strict' => true to 'strict' => false

(https://github.com/laravel/framework/issues/14997#issuecomment-242129087)

  1. Add to config/auth.php:

    'guards' => [
        'admin' => [
            'driver' => 'session',
            'provider' => 'admins',
        ],
    'providers' => [
        'admins' => [
            'driver' => 'eloquent',
            'model' => Wbe\Crud\Models\ContentTypes\User::class,
        ],
    'passwords' => [
        'admins' => [
            'provider' => 'admins',
            'table' => 'password_resets',
            'expire' => 60,
        ],
  2. Add to config/app.php:

'providers' => [
        App\Providers\AppServiceProvider::class,
        App\Providers\AuthServiceProvider::class,
        // App\Providers\BroadcastServiceProvider::class,
        App\Providers\EventServiceProvider::class,
        App\Providers\RouteServiceProvider::class,

        Laravel\Socialite\SocialiteServiceProvider::class,
        //Barryvdh\LaravelIdeHelper\IdeHelperServiceProvider::class,
        Zofe\Rapyd\RapydServiceProvider::class,
        //Laravel\Cashier\CashierServiceProvider::class,
        Barryvdh\Elfinder\ElfinderServiceProvider::class,
        
        Wbe\Crud\Models\hrbac\HierarchicalRBAC\HRBACServiceProvider::class,
        Wbe\Crud\CrudServiceProvider::class
'aliases' => [
        'Form' => Collective\Html\FormFacade::class,
        'Html' => Collective\Html\HtmlFacade::class,
        'Socialite' => Laravel\Socialite\Facades\Socialite::class,
        //'DataEdit' => Zofe\Rapyd\DataEdit\DataEdit::class,
  1. Add helper.php to composer autoload section:
  "files": [
    "vendor/wbe/crud/src/helpers.php"
  ]
  1. Add to app\Http\Kernel.php:
protected $middleware = [
        \Illuminate\Session\Middleware\StartSession::class,
        \Wbe\Crud\Middleware\Locale::class,
        \Wbe\Crud\Middleware\LangMiddleware::class,
        \Wbe\Crud\Middleware\AdminAccessMiddleware::class,
protected $routeMiddleware = [
        'customer' => \Wbe\Crud\Middleware\RedirectIfNotCustomer::class,
        'customer.guest' => \Wbe\Crud\Middleware\RedirectIfCustomer::class,
        'admin' => \Wbe\Crud\Middleware\RedirectIfNotAdmin::class,
        'admin.guest' => \Wbe\Crud\Middleware\RedirectIfAdmin::class,
 protected $middlewareGroups = [
         'admin'=>[
                     \Illuminate\View\Middleware\ShareErrorsFromSession::class,
                 ],
  1. Run into console:
php artisan vendor:publish --provider="Zofe\Rapyd\RapydServiceProvider"
php artisan vendor:publish --provider="Wbe\Crud\CrudServiceProvider"
php artisan elfinder:publish
php artisan migrate
php artisan db:seed --class="\Wbe\Crud\seeds\DatabaseSeeder"
composer dump-autoload
mkdir public/files/

add alias

auto generate alias if in description table exist column alias generate alias willbe from column title

add redirect config configuration from add page

in config/crud.php

'edit_redirect' => env('edit_redirect', 1)

by default 1

1 - redirect to edit page 0 - redirect to data page

Migrations will create tables and fill it with default data. It also contains data insertions into database (like seeding).

Finally, admin url:

http://yourproject.dev/admin/

Login: admin@gmail.com

Pass: 111111