Skip to content

Resources

Marcin Halak (Versoo) edited this page Apr 10, 2018 · 2 revisions

Command: larapi:resource

Command will create full resource directory structure with all basic files.

php artisan larapi:resource {Resource} --all

You can select single files which you need in resource. Example, will create resource only with pricate routes, model and repository:

php artisan larapi:resource {Resource} --routes --model --repository

Arguments:

  • Resource - Name of Resource, it will be used to create name of all others files

Options:

  • -a, --all - Command will created whole basic Resource folder structure
  • --controller - Create Resource folder with Controller
  • --routes - Create Resource folder with Routes
  • --model - Create Resource folder with Model
  • --repository - Create Resource folder with Repository
  • --service - Create Resource folder with Service
  • --provider - Create Resource folder with Provider
  • --events - Create Resource folder with basic Events
  • --request - Create Resource folder with basic Request
  • --exception - Create Resource folder with basic Exception
Clone this wiki locally