@@ -4,7 +4,7 @@ |
||
| 4 | 4 | |
| 5 | 5 | use Illuminate\Support\Facades\App; |
| 6 | 6 | |
| 7 | -trait MakeRoutes{ |
|
| 7 | +trait MakeRoutes { |
|
| 8 | 8 | /** |
| 9 | 9 | * @param $module |
| 10 | 10 | */ |
@@ -4,7 +4,7 @@ discard block |
||
| 4 | 4 | |
| 5 | 5 | use Illuminate\Support\Facades\App; |
| 6 | 6 | |
| 7 | -trait MakeController{ |
|
| 7 | +trait MakeController { |
|
| 8 | 8 | |
| 9 | 9 | /** |
| 10 | 10 | * @param $module |
@@ -20,7 +20,7 @@ discard block |
||
| 20 | 20 | base_path() . "/app/Modules/" . $module . "/Controllers/" . $filename . ".php", |
| 21 | 21 | $this->compileControllerStub($module, $filename) |
| 22 | 22 | ); |
| 23 | - (file_exists(base_path() . "/app/Modules/" . $module . "/Controllers/" . $filename . ".php") ? $this->info('Done'):$this->error('An error occurred')); |
|
| 23 | + (file_exists(base_path() . "/app/Modules/" . $module . "/Controllers/" . $filename . ".php") ? $this->info('Done') : $this->error('An error occurred')); |
|
| 24 | 24 | return; |
| 25 | 25 | } |
| 26 | 26 | $this->error('Controller already exists'); |
@@ -50,7 +50,7 @@ discard block |
||
| 50 | 50 | |
| 51 | 51 | return str_replace( |
| 52 | 52 | ['DummyNamespace', 'DummyClass', 'DummyRootNamespaceHttp'], |
| 53 | - [App::getNamespace() . 'Modules\\' . $moduleName . '\Controllers', $className, App::getNamespace() .'Http'], |
|
| 53 | + [App::getNamespace() . 'Modules\\' . $moduleName . '\Controllers', $className, App::getNamespace() . 'Http'], |
|
| 54 | 54 | file_get_contents($stub) |
| 55 | 55 | ); |
| 56 | 56 | } |
@@ -113,7 +113,7 @@ |
||
| 113 | 113 | $this->warn('Options:'); |
| 114 | 114 | $this->info(' --create - Creates the folder structure and web routes file for a module'); |
| 115 | 115 | $this->info(' --controller [FileName] [--plain] - Creates a controller for the module given - add'. |
| 116 | - ' --plain to create an empty controller.'); |
|
| 116 | + ' --plain to create an empty controller.'); |
|
| 117 | 117 | // $this->info(' --migration [FileName] - Creates a migration for the module given'); |
| 118 | 118 | // $this->info(' --model [FileName] - Creates a model for the module given'); |
| 119 | 119 | $this->info(' --webroute - Creates a web routes file for the module given'); |
@@ -83,10 +83,10 @@ discard block |
||
| 83 | 83 | } |
| 84 | 84 | |
| 85 | 85 | // Has a File Name been given? |
| 86 | - if($this->isFileNameGiven($filename)){ |
|
| 86 | + if ($this->isFileNameGiven($filename)) { |
|
| 87 | 87 | |
| 88 | 88 | // Create Controller |
| 89 | - if($this->option('controller')) { |
|
| 89 | + if ($this->option('controller')) { |
|
| 90 | 90 | return $this->createController($module, $filename); |
| 91 | 91 | } |
| 92 | 92 | } |
@@ -112,7 +112,7 @@ discard block |
||
| 112 | 112 | $this->line(''); |
| 113 | 113 | $this->warn('Options:'); |
| 114 | 114 | $this->info(' --create - Creates the folder structure and web routes file for a module'); |
| 115 | - $this->info(' --controller [FileName] [--plain] - Creates a controller for the module given - add'. |
|
| 115 | + $this->info(' --controller [FileName] [--plain] - Creates a controller for the module given - add' . |
|
| 116 | 116 | ' --plain to create an empty controller.'); |
| 117 | 117 | // $this->info(' --migration [FileName] - Creates a migration for the module given'); |
| 118 | 118 | // $this->info(' --model [FileName] - Creates a model for the module given'); |