K
K
Konstantin B.2018-08-01 13:07:07
Laravel
Konstantin B., 2018-08-01 13:07:07

What is the best way to manage notification settings in Laravel?

Laravel can work with notifications out of the box. But what is the best way to work with them when settings are needed. Let's say we have various events for which the user can specify which event to notify, let's say Email, Push or SMS. Unfortunately, the search engines give out nothing more than information in the dock, but I don’t quite understand how to do this, I understand it more precisely, but I don’t understand how to do this through a boxed solution

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alexey Ukolov, 2018-08-01
@Kostik_1993

What exactly is your question? It comes to the method via()of the notification object $notifiable- there you can return the necessary channels or an empty array based on the settings so that the notification is not sent at all.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question