Create TO ftn (for netmails), identify REPLYID, add file:list

This commit is contained in:
Deon George
2022-11-11 22:57:40 +11:00
parent 6284016400
commit eab36c1603
7 changed files with 88 additions and 17 deletions

View File

@@ -7,7 +7,7 @@ use Symfony\Component\HttpFoundation\File\File;
use App\Classes\FTN\Packet;
use App\Jobs\MessageProcess as Job;
use App\Models\Zone;
use App\Models\Address;
class PacketProcess extends Command
{
@@ -19,7 +19,7 @@ class PacketProcess extends Command
protected $signature = 'packet:process'
.' {pkt : Packet to process}'
.' {--N|nobot : Dont process bots}'
.' {system? : Zone the packet is from}';
.' {ftn? : System the packet is from}';
/**
* The console command description.
@@ -37,7 +37,7 @@ class PacketProcess extends Command
public function handle()
{
$f = new File($this->argument('pkt'));
$s = $this->argument('system') ? Zone::where('name',$this->argument('system'))->singleOrFail() : NULL;
$s = $this->argument('ftn') ? Address::findFTN($this->argument('ftn'))->system : NULL;
foreach (Packet::open($f,$s) as $msg) {
// @todo Quick check that the packet should be processed by us.