lupka/crudder

Dead simple admin panels for Laravel.

Maintainers

Details

github.com/lupka/crudder

Source

Issues

Installs: 13

Dependents: 0

Suggesters: 0

Security: 0

Stars: 2

Watchers: 2

Forks: 0

Open Issues: 0

Type:package

0.0.1 2017-01-16 09:34 UTC

This package is auto-updated.

Last update: 2024-04-22 16:35:13 UTC


README

This is still under development, DO NOT USE IN PRODUCTION

Crudder

[icense](LICENSE)

Installation

1: Install via Composer

composer require lupka/crudder

2: Add Service Provider

Add the new provider to the providers array of config/app.php:

'providers' => [
    // ...
    Lupka\Crudder\CrudderServiceProvider::class,
    // ...
],

3: Add Facade

Add the new Crudder alias to the aliases array of config/app.php:

'aliases' => [
    // ...
    'Crudder' => Lupka\Crudder\CrudderFacade::class,
    // ...
],

4: Add routes

Add a call to Crudder::routes() wherever you want within your routes file. The example below uses a route group with a prefix and auth middleware:

Route::group(['prefix' => 'crudder', 'middleware' => 'auth'], function(){
    Crudder::routes();
});

5: Publish config file

Publish the Crudder config file by running the following command:

php artisan vendor:publish --tag=config

Configuration

Basic Setup

All you need to do to get started is enter the class name of the Eloquent Model you want to have an admin for in the crudder.php config file.

    'models' => [
        'App\BlogPost' => []    
    ]

Crudder will use a basic form based on the field types in your database.

Tips

If you want to modify values programmatically before/after saving, I recommend using observers: https://laravel.com/docs/5.3/eloquent#observers