laravel-liberu /
genealogy
| 1 | <?php |
||
| 2 | |||
| 3 | namespace App\Providers; |
||
| 4 | |||
| 5 | use Illuminate\Support\Facades\Gate; |
||
| 6 | use Laravel\Horizon\Horizon; |
||
| 7 | use Laravel\Horizon\HorizonApplicationServiceProvider; |
||
| 8 | |||
| 9 | class HorizonServiceProvider extends HorizonApplicationServiceProvider |
||
| 10 | { |
||
| 11 | public function boot() |
||
| 12 | { |
||
| 13 | parent::boot(); |
||
| 14 | |||
| 15 | // Horizon::routeSmsNotificationsTo('15556667777'); |
||
| 16 | // Horizon::routeMailNotificationsTo('[email protected]'); |
||
| 17 | // Horizon::routeSlackNotificationsTo('slack-webhook-url', '#channel'); |
||
| 18 | |||
| 19 | Horizon::night(); |
||
|
0 ignored issues
–
show
Deprecated Code
introduced
by
Loading history...
|
|||
| 20 | } |
||
| 21 | |||
| 22 | protected function gate() |
||
| 23 | { |
||
| 24 | Gate::define('viewHorizon', fn ($user) => $user?->isAdmin()); |
||
| 25 | } |
||
| 26 | } |
||
| 27 |