public function markAllAsSeenAction($notifiable)
    {
        $manager = $this->get('mgilet.notification');
        $manager->markAllAsSeen(
            $manager->getNotifiableInterface($manager->getNotifiableEntityById($notifiable)),
            true
        );

        return new JsonResponse(true);
    }
public function markAllAsSeenAction($notifiable)
    {
        $manager = $this->get('mgilet.notification');
        $manager->markAllAsSeen(
            $manager->getNotifiableInterface($manager->getNotifiableEntityById($notifiable)),
            true
        );

        return new JsonResponse(true);
    }
public function markAllAsSeenAction ( $ notifiable ) { $ manager = $ this -> get ( 'mgilet.notification' ) ; $ manager -> markAllAsSeen ( $ manager -> getNotifiableInterface ( $ manager -> getNotifiableEntityById ( $ notifiable ) ) , true ) ; return new JsonResponse ( true ) ; }
Set all Notifications for a User as seen

@Route("/{notifiable}/markAllAsSeen", name="notification_mark_all_as_seen")
@Method("POST")
@param $notifiable

@return JsonResponse
@throws \RuntimeException
@throws \InvalidArgumentException
@throws \Doctrine\ORM\OptimisticLockException
Set all Notifications for a User as seen