2022-11-01 11:24:36 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
namespace App\Console\Commands;
|
|
|
|
|
|
|
|
use Illuminate\Console\Command;
|
|
|
|
|
|
|
|
use App\Jobs\TicProcess as Job;
|
|
|
|
|
|
|
|
class TicProcess extends Command
|
|
|
|
{
|
|
|
|
/**
|
|
|
|
* The name and signature of the console command.
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
2022-11-11 12:34:33 +00:00
|
|
|
protected $signature = 'tic:process'
|
|
|
|
.' {file : TIC file}'
|
|
|
|
.' {domain? : Domain Name}';
|
2022-11-01 11:24:36 +00:00
|
|
|
|
|
|
|
/**
|
|
|
|
* The console command description.
|
|
|
|
*
|
|
|
|
* @var string
|
|
|
|
*/
|
|
|
|
protected $description = 'Process a TIC file';
|
|
|
|
|
|
|
|
/**
|
|
|
|
* Execute the console command.
|
|
|
|
*
|
|
|
|
* @return int
|
|
|
|
*/
|
|
|
|
public function handle()
|
|
|
|
{
|
|
|
|
// Dispatch job.
|
2022-11-11 12:34:33 +00:00
|
|
|
Job::dispatchSync($this->argument('file'),$this->argument('domain'));
|
2022-11-01 11:24:36 +00:00
|
|
|
|
|
|
|
return Command::SUCCESS;
|
|
|
|
}
|
|
|
|
}
|