clrghouz/app/Console/Commands/TicProcess.php

37 lines
631 B
PHP
Raw Permalink Normal View History

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
{
2023-06-27 07:39:11 +00:00
/**
* The name and signature of the console command.
*
* @var string
*/
protected $signature = 'tic:process'
.' {file : TIC file}'
.' {domain? : Domain Name}';
2022-11-01 11:24:36 +00:00
2023-06-27 07:39:11 +00:00
/**
* The console command description.
*
* @var string
*/
protected $description = 'Process a TIC file';
2022-11-01 11:24:36 +00:00
2023-06-27 07:39:11 +00:00
/**
* Execute the console command.
*
* @return int
*/
public function handle(): int
2023-06-27 07:39:11 +00:00
{
2022-11-01 11:24:36 +00:00
// Dispatch job.
return Job::dispatchSync($this->argument('file'),$this->argument('domain'));
2023-06-27 07:39:11 +00:00
}
}