Наследование: extends Illuminate\Console\GeneratorCommand
Пример #1
0
 /**
  * Execute the console command.
  *
  * @return void
  */
 public function fire()
 {
     if (parent::fire() !== false) {
         if ($this->option('migration')) {
             $table = Str::plural(Str::snake(class_basename($this->argument('name'))));
             $this->call('make:module:migration', ['slug' => $this->argument('slug'), 'name' => "create_{$table}_table", '--create' => $table]);
         }
     }
 }