Changeset View
Changeset View
Standalone View
Standalone View
src/app/Console/Commands/Data/ImportCommand.php
- This file was copied to src/app/Console/Commands/Data/ExportCommand.php.
Show All 12 Lines | class ImportCommand extends Command | ||||
*/ | */ | ||||
protected $signature = 'data:import'; | protected $signature = 'data:import'; | ||||
/** | /** | ||||
* The console command description. | * The console command description. | ||||
* | * | ||||
* @var string | * @var string | ||||
*/ | */ | ||||
protected $description = 'Command description'; | protected $description = 'Import data from external sources'; | ||||
/** | /** | ||||
* Create a new command instance. | * Create a new command instance. | ||||
* | * | ||||
* @return void | * @return void | ||||
*/ | */ | ||||
public function __construct() | public function __construct() | ||||
{ | { | ||||
Show All 13 Lines | public function handle() | ||||
Import\IP6NetsCommand::class | Import\IP6NetsCommand::class | ||||
]; | ]; | ||||
foreach ($commands as $command) { | foreach ($commands as $command) { | ||||
$execution = new $command(); | $execution = new $command(); | ||||
$execution->output = $this->output; | $execution->output = $this->output; | ||||
$execution->handle(); | $execution->handle(); | ||||
} | } | ||||
return 0; | |||||
} | } | ||||
} | } |