public function notificationsAction($offset = 0)
{
$usersId = $this->session->get('identity');
if (!$usersId) {
$this->flashSession->error('You must be logged first');
return $this->response->redirect();
}
$user = Users::findFirstById($usersId);
if (!$user) {
$this->flashSession->error('The user does not exist');
return $this->response->redirect();
}
$this->view->user = $user;
$this->view->notifications = ActivityNotifications::find(['users_id = ?0', 'bind' => [$usersId], 'limit' => 128, 'order' => 'created_at DESC']);
$this->tag->setTitle('Notifications');
}