Fix routed netmails being packed for the hub, not the destination. Added some logging for idle netmails/emails

This commit is contained in:
2024-05-26 20:53:59 +10:00
parent 03bfc9dbfc
commit 7e0178d183
9 changed files with 38 additions and 22 deletions

View File

@@ -7,6 +7,7 @@ use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Notifications\Messages\MailMessage;
use Illuminate\Notifications\Notification;
use Illuminate\Support\Facades\Log;
use App\Models\Address;
@@ -14,6 +15,8 @@ class NodeDelisted extends Notification //implements ShouldQueue
{
use Queueable;
private const LOGKEY = 'NED';
/**
* Create a new notification instance.
*/
@@ -36,6 +39,8 @@ class NodeDelisted extends Notification //implements ShouldQueue
*/
public function toMail(object $notifiable): MailMessage
{
Log::info(sprintf('%s:+ Sending a NODE DELISTED EMAIL for address [%s]',self::LOGKEY,$this->ao->ftn));
$now = Carbon::now();
return (new MailMessage)

View File

@@ -7,6 +7,7 @@ use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Notifications\Messages\MailMessage;
use Illuminate\Notifications\Notification;
use Illuminate\Support\Facades\Log;
use App\Models\Address;
@@ -14,6 +15,8 @@ class NodeMarkedDown extends Notification //implements ShouldQueue
{
use Queueable;
private const LOGKEY = 'NEM';
/**
* Create a new notification instance.
*/
@@ -36,6 +39,8 @@ class NodeMarkedDown extends Notification //implements ShouldQueue
*/
public function toMail(object $notifiable): MailMessage
{
Log::info(sprintf('%s:+ Sending a NODE MARKED DOWN EMAIL for address [%s]',self::LOGKEY,$this->ao->ftn));
$now = Carbon::now();
return (new MailMessage)

View File

@@ -7,6 +7,7 @@ use Illuminate\Bus\Queueable;
use Illuminate\Contracts\Queue\ShouldQueue;
use Illuminate\Notifications\Messages\MailMessage;
use Illuminate\Notifications\Notification;
use Illuminate\Support\Facades\Log;
use App\Models\Address;
@@ -14,6 +15,8 @@ class NodeMarkedHold extends Notification //implements ShouldQueue
{
use Queueable;
private const LOGKEY = 'NEH';
/**
* Create a new notification instance.
*/
@@ -36,6 +39,8 @@ class NodeMarkedHold extends Notification //implements ShouldQueue
*/
public function toMail(object $notifiable): MailMessage
{
Log::info(sprintf('%s:+ Sending a NODE MARKED HOLD EMAIL for address [%s]',self::LOGKEY,$this->ao->ftn));
$now = Carbon::now();
return (new MailMessage)