diff options
Diffstat (limited to 'app/Console/Commands/SaveSeasonAiring.php')
| -rw-r--r-- | app/Console/Commands/SaveSeasonAiring.php | 43 |
1 files changed, 43 insertions, 0 deletions
diff --git a/app/Console/Commands/SaveSeasonAiring.php b/app/Console/Commands/SaveSeasonAiring.php new file mode 100644 index 0000000..5bee978 --- /dev/null +++ b/app/Console/Commands/SaveSeasonAiring.php @@ -0,0 +1,43 @@ +<?php + +namespace App\Console\Commands; + +use Illuminate\Console\Command; +use App\Libraries\Background; + +class SaveSeasonAiring extends Command +{ + /** + * The name and signature of the console command. + * + * @var string + */ + protected $signature = 'anime:saveSeasonAiring'; + + /** + * The console command description. + * + * @var string + */ + protected $description = 'Save seasonal anime and airing status'; + + /** + * Execute the console command. + * + * @return int + */ + public function handle() + { + $background = new Background(); + echo "SaveSeason(): \n"; + $background->saveSeason(); + sleep(10); + echo "\ncheckIfIsAiring(): \n"; + $background->checkIfIsAiring(); + sleep(10); + echo "\nsaveAiringForAll(): \n"; + $background->saveAiringForAll(); + + return Command::SUCCESS; + } +} |
