chanaged logic for rfq transporter bid
Some checks failed
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (push) Successful in 10s
Scan for leaked secrets using Kingfisher / kingfisher-secrets-scan (pull_request) Successful in 10s
Gemini PR Review / Gemini PR Review (pull_request) Successful in 13s
Laravel Pint / pint (pull_request) Failing after 2m20s
Laravel Larastan / larastan (pull_request) Failing after 2m22s

This commit is contained in:
dhanabalan
2026-01-24 12:41:06 +05:30
parent 20b17d446b
commit 28503a25c3
2 changed files with 44 additions and 12 deletions

View File

@@ -17,9 +17,18 @@ class PushAlertNotification extends Notification
/**
* Create a new notification instance.
*/
public function __construct()
// public function __construct()
// {
// //
// }
public $title;
public $body;
public function __construct($title, $body)
{
//
$this->title = $title;
$this->body = $body;
}
public function via($notifiable)
@@ -27,12 +36,22 @@ class PushAlertNotification extends Notification
return [WebPushChannel::class];
}
// public function toWebPush($notifiable, $notification)
// {
// return (new WebPushMessage)
// ->title('New Alert 🚨')
// ->icon('/pwa-192x192.png')
// ->body('You have a new notification')
// ->action('Open App', 'open_app')
// ->data(['url' => '/admin']);
// }
public function toWebPush($notifiable, $notification)
{
return (new WebPushMessage)
->title('New Alert 🚨')
->title($this->title)
->icon('/pwa-192x192.png')
->body('You have a new notification')
->body($this->body)
->action('Open App', 'open_app')
->data(['url' => '/admin']);
}
@@ -50,13 +69,13 @@ class PushAlertNotification extends Notification
/**
* Get the mail representation of the notification.
*/
public function toMail(object $notifiable): MailMessage
{
return (new MailMessage)
->line('The introduction to the notification.')
->action('Notification Action', url('/'))
->line('Thank you for using our application!');
}
// public function toMail(object $notifiable): MailMessage
// {
// return (new MailMessage)
// ->line('The introduction to the notification.')
// ->action('Notification Action', url('/'))
// ->line('Thank you for using our application!');
// }
/**
* Get the array representation of the notification.