LaravelPackages.net
Acme Inc.
Toggle sidebar
joselee214/laravel

Ypc ... Components for Laravel Framework code generation. focker from reliese/laravel @ Cristian Llanos .

134
0
v0.0.26
About joselee214/laravel

joselee214/laravel is a Laravel package for ypc ... components for laravel framework code generation. focker from reliese/laravel @ cristian llanos .. It currently has 0 GitHub stars and 134 downloads on Packagist (latest version v0.0.26). Install it with composer require joselee214/laravel. Discover more Laravel packages by joselee214 or browse all Laravel packages to compare alternatives.

Last updated

composer require joselee214/laravel

Add the service provider to your config/app.php file within the providers key:

// ...
'providers' => [
    /*
     * Package Service Providers...
     */

    Joselee214\Ypc\Joselee214ServiceProvider::class,
],
// ...

Configuration for local environment only

If you wish to enable generators only for your local environment, you should install it via composer using the --dev option like this:

composer require joselee214/laravel --dev

Then you'll need to register the provider in app/Providers/AppServiceProvider.php file.

public function register()
{
    if ($this->app->environment() == 'local') {
        $this->app->register(\Joselee214\Ypc\Joselee214ServiceProvider::class);
    }
}

Models

Generating models with artisan

Add the models.php configuration file to your config directory and clear the config cache:

php artisan vendor:publish --tag=Joselee214-models
php artisan config:clear

Usage

Assuming you have already configured your database, you are now all set to go.

  • Let's scaffold some of your models from your default connection.
php artisan zz:models
  • You can scaffold a specific table like this:
php artisan zz:models --table=users
  • You can also specify the connection:
php artisan zz:models --connection=mysql
  • If you are using a MySQL database, you can specify which schema you want to scaffold:
php artisan zz:models --schema=shop

Star History Chart