VPS and dedicated server ordering, managed panels, SSO, billing, and launcher integration — forked from hosting infrastructure with server-focused routes and dashboard. Co-authored-by: Cursor <cursoragent@cursor.com>
25 lines
599 B
PHP
25 lines
599 B
PHP
<?php
|
|
|
|
namespace App\Console\Commands;
|
|
|
|
use App\Services\Hosting\HostingExpiryAlertService;
|
|
use Illuminate\Console\Command;
|
|
|
|
class NotifyExpiringHostingCommand extends Command
|
|
{
|
|
protected $signature = 'hosting:notify-expiring';
|
|
|
|
protected $description = 'Send hosting plan expiry reminder emails';
|
|
|
|
public function handle(HostingExpiryAlertService $alerts): int
|
|
{
|
|
$sent = $alerts->checkAll();
|
|
|
|
$this->info($sent > 0
|
|
? "Sent {$sent} hosting expiry reminder(s)."
|
|
: 'No hosting expiry reminders to send.');
|
|
|
|
return self::SUCCESS;
|
|
}
|
|
}
|