whoami7 - Manager
:
/
home
/
kckglobal
/
public_html
/
portal
/
app
/
Listeners
/
Upload File:
files >> /home/kckglobal/public_html/portal/app/Listeners/DiscussionReplyListener.php
<?php namespace App\Listeners; use App\Events\DiscussionReplyEvent; use App\Notifications\NewDiscussionReply; use Illuminate\Support\Facades\Notification; class DiscussionReplyListener { /** * Handle the event. * * @param DiscussionReplyEvent $event * @return void */ public function handle(DiscussionReplyEvent $event) { $client = $event->discussionReply?->discussion?->project?->client; if ($client) { Notification::send($client, new NewDiscussionReply($event->discussionReply)); } Notification::send($event->notifyUser, new NewDiscussionReply($event->discussionReply)); } }
Copyright ©2021 || Defacer Indonesia