PHP Artisan Make Command: Model Does Not Work

0

I'm using Composer to generate my PHP files and stuff. I think it makes programming much easier.

For example, to generate a Controller I do this:

php artisan controller:make NomeController

It works!

But typing:

php artisan make:model NomeModel

It does not work and displays this error:

  

There are no commands defined in the "make" namespace.

I searched, but found nothing. And I noticed that typing only php artisan - which shows a list of existing commands - model does not really exist.

What to do?

    
asked by anonymous 13.05.2015 / 14:48

1 answer

2

It would not be:

php artisan model:make NomeModel 

You can also use the command:

php artisan 

To list all commands.

If you do not have it, you can use the Laravel 4 Generators extension that meets your needs.

Adding some new features to your artisan:

generate:model
generate:view
generate:controller
generate:seed
generate:migration
generate:pivot
generate:resource
generate:scaffold
    
13.05.2015 / 15:07