Reputation: 3437
I'm using Jeffrey Way
Generator
to generate my controller, but in Laravel 4
's version, I cant find a way to generate a controller with its list of methods.
This command: php artisan generate:controller
, gives me a controller with a predefined template, but I want to declare these methods on my own.
Upvotes: 1
Views: 10922
Reputation: 5596
Go to the project route directory in Command prompt
cd c:\xampp\htdocs\ProjectName
then run the command php artisan controller:make XYZController
like this
c:\xampp\htdocs\ProjectName>php artisan controller:make XYZController
now it will creates a controller with the name XYZController.php in your Controllers folder i.e
c:\xampp\htdocs\ProjectName\app\controllers\XYZController.php
njoy!!.
Upvotes: 5
Reputation: 4272
Looking at the source, it doesn't appear that the Generator package currently does this. You might send a feature request: https://github.com/JeffreyWay/Laravel-4-Generators/issues
Upvotes: 2