ldc-legaulois/app/Console/Commands/RefreshSiteMap.php

39 lines
780 B
PHP
Raw Normal View History

<?php
namespace App\Console\Commands;
use App\Jobs\RefreshSiteMap as JobsRefreshSiteMap;
use Illuminate\Console\Command;
class RefreshSiteMap extends Command
{
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'sitemap:refresh';
/**
* The console command description.
*
* @var string
*/
protected $description = 'Run the RefreshSiteMapJob manually';
/**
* Execute the console command.
*
* @return int
*/
public function handle()
{
$this->info('Running the Job, this could take some time.');
$job = new JobsRefreshSiteMap();
$job->console = $this;
$job->handle();
$this->info('Job completed');
}
}