butoibogdan / crud-generator
Laravel5 CRUD Generator
dev-master
2015-06-26 07:44 UTC
Requires
- php: >=5.4.0
- illuminate/html: 5.0.*
- illuminate/support: ~5.0
This package is not auto-updated.
Last update: 2024-12-21 18:49:55 UTC
README
Laravel CRUD Generator
Installation
-
Run
composer require "appzcoder/crud-generator":"dev-master"
-
Add service provider into /config/app.php file.
'providers' => [ ... 'Appzcoder\CrudGenerator\CrudGeneratorServiceProvider', ],
Add bellow lines for "illuminate/html" package if you've not done yet.
'providers' => [ ... 'Illuminate\Html\HtmlServiceProvider', ], 'aliases' => [ ... 'Form'=> 'Illuminate\Html\FormFacade', 'HTML'=> 'Illuminate\Html\HtmlFacade', ],
-
Run composer update
Note: You should have configured database as well for this operation.
Commands
Crud command:
php artisan crud:generate crud-name --fields="name:string, email:string, phone:integer, message:text"
Others command (optional):
For controller generator:
php artisan crud:controller NameController --crud-name="Name"
For model generator:
php artisan crud:model Name --fillable="['name', 'email', 'message']"
For migration generator:
php artisan crud:migration migration-name --schema="name:string, email:string, phone:integer, message:text"
For view generator:
php artisan crud:view crud-name --fields="name:string, email:string, phone:integer, message:text"
##Author