Want to access all of our courses? (30 h 09 min)
You also get:
Already a member? Login here
I can't understand what this is for?
switch ($this->notification->notification_class) { case BookingReminder1H::class: $this->notification->user->notify(new BookingReminder1H($this->notification->notifiable)); break; case BookingReminder2H::class: $this->notification->user->notify(new BookingReminder2H($this->notification->notifiable)); break; case BookingReminder5MIN::class: $this->notification->user->notify(new BookingReminder5MIN($this->notification->notifiable)); break; case BookingStartedNotification::class: $this->notification->user->notify(new BookingStartedNotification($this->notification->notifiable)); break;}
this allows us to switch notification class based on what we saved in database. this allows us to quickly add/remove/replace notification classes
Your reminder classes should simply implement the BookingReminderInterface.
This was not the goal of this lesson :)
We don't want to add complications around things, when it is not the focus of a lesson
Tell us what you like or what we can improve
Feel free to share anything you like or dislike about this page or the platform in general.
Your feedback has been received. We truly appreciate you taking the time to help us improve.
I can't understand what this is for?
this allows us to switch notification class based on what we saved in database. this allows us to quickly add/remove/replace notification classes
Your reminder classes should simply implement the BookingReminderInterface.
This was not the goal of this lesson :)
We don't want to add complications around things, when it is not the focus of a lesson