34 lines
898 B
PHP
34 lines
898 B
PHP
|
<?php
|
||
|
|
||
|
namespace Notification\Admin;
|
||
|
|
||
|
use Notification;
|
||
|
require_once 'Notification.php';
|
||
|
|
||
|
class UserRegisteredNotification extends \Notification
|
||
|
{
|
||
|
public function __construct(array $data)
|
||
|
{
|
||
|
$data['type'] = 'admin.newUserRegistered';
|
||
|
parent::__construct($data);
|
||
|
}
|
||
|
|
||
|
public function getNotificationLink()
|
||
|
{
|
||
|
return '/user/' . $this->sender->getUsername();
|
||
|
}
|
||
|
|
||
|
public function getNotificationImage()
|
||
|
{
|
||
|
return $this->sender->getProfilePicture();
|
||
|
}
|
||
|
|
||
|
public function messageForNotification(Notification $notification)
|
||
|
{
|
||
|
return ['line' => 'admin.newUserRegistered.single', 'attributes' => [$this->sender->getName()]];
|
||
|
}
|
||
|
|
||
|
public function messageForNotifications(array $notifications, $realCount = 0)
|
||
|
{
|
||
|
}
|
||
|
}
|