Loading module/Oscar/src/Oscar/Command/OscarNotificationsMailsPersonsCommand.php +1 −4 Changes for module/Oscar/src/Oscar/Command/OscarNotificationsMailsPersonsCommand.php: 1 added line, 4 removed lines. Original line number Diff line number Diff line Loading @@ -26,12 +26,9 @@ class OscarNotificationsMailsPersonsCommand extends OscarCommandAbstract { $this->addOutputStyle($output); /** @var OscarUserContext $oscaruserContext */ $oscaruserContext = $this->getServicemanager()->get(OscarUserContext::class); $io = new SymfonyStyle($input, $output); /** @var PersonService $oscarConfig */ /** @var PersonService $personService */ $personService = $this->getServicemanager()->get(PersonService::class); $personService->mailPersonsWithUnreadNotification(null, $io); Loading module/Oscar/src/Oscar/Service/OscarUserContext.php +1 −1 Changes for module/Oscar/src/Oscar/Service/OscarUserContext.php: 1 added line, 1 removed line. Original line number Diff line number Diff line Loading @@ -318,7 +318,7 @@ class OscarUserContext implements UseOscarConfigurationService, UseLoggerService public function getAuthentification() { if ($this->getUserContext()->getDbUser()) { return $this->getEntityManager()->getRepository(Authentification::class)->find($this->getDbUser()->getId()); return $this->getAuthentificationRepository()->find($this->getDbUser()->getId()); } return null; } Loading module/Oscar/src/Oscar/Service/PersonService.php +7 −4 Changes for module/Oscar/src/Oscar/Service/PersonService.php: 7 added lines, 4 removed lines. Original line number Diff line number Diff line Loading @@ -486,9 +486,6 @@ class PersonService implements UseOscarConfigurationService, UseEntityManager, U $authPersonNormalize = $this->getOscarConfigurationService()->getAuthPersonNormalize(); /** @var AuthentificationRepository $authentificationRepository */ $authentificationRepository = $this->getEntityManager()->getRepository(Authentification::class); // Liste des personnes ayant des notifications non-lues $persons = $this->getPersonRepository()->getPersonsWithUnreadNotificationsAndAuthentification($authPersonNormalize); Loading @@ -498,7 +495,7 @@ class PersonService implements UseOscarConfigurationService, UseEntityManager, U foreach ($persons as $person) { try { /** @var Authentification $auth */ $auth = $authentificationRepository->getAuthentificationPerson($person, $authPersonNormalize); $auth = $this->getPersonAuthentification($person); $settings = $auth->getSettings(); if (!$settings) { Loading Loading @@ -1924,11 +1921,17 @@ class PersonService implements UseOscarConfigurationService, UseEntityManager, U return $this->getEntityManager()->getRepository(Authentification::class); } /** * @return OrganizationRepository */ public function getOrganizationRepository() { return $this->getEntityManager()->getRepository(Organization::class); } /** * @return RoleRepository */ public function getRoleRepository(): RoleRepository { return $this->getEntityManager()->getRepository(Role::class); Loading Loading
module/Oscar/src/Oscar/Command/OscarNotificationsMailsPersonsCommand.php +1 −4 Changes for module/Oscar/src/Oscar/Command/OscarNotificationsMailsPersonsCommand.php: 1 added line, 4 removed lines. Original line number Diff line number Diff line Loading @@ -26,12 +26,9 @@ class OscarNotificationsMailsPersonsCommand extends OscarCommandAbstract { $this->addOutputStyle($output); /** @var OscarUserContext $oscaruserContext */ $oscaruserContext = $this->getServicemanager()->get(OscarUserContext::class); $io = new SymfonyStyle($input, $output); /** @var PersonService $oscarConfig */ /** @var PersonService $personService */ $personService = $this->getServicemanager()->get(PersonService::class); $personService->mailPersonsWithUnreadNotification(null, $io); Loading
module/Oscar/src/Oscar/Service/OscarUserContext.php +1 −1 Changes for module/Oscar/src/Oscar/Service/OscarUserContext.php: 1 added line, 1 removed line. Original line number Diff line number Diff line Loading @@ -318,7 +318,7 @@ class OscarUserContext implements UseOscarConfigurationService, UseLoggerService public function getAuthentification() { if ($this->getUserContext()->getDbUser()) { return $this->getEntityManager()->getRepository(Authentification::class)->find($this->getDbUser()->getId()); return $this->getAuthentificationRepository()->find($this->getDbUser()->getId()); } return null; } Loading
module/Oscar/src/Oscar/Service/PersonService.php +7 −4 Changes for module/Oscar/src/Oscar/Service/PersonService.php: 7 added lines, 4 removed lines. Original line number Diff line number Diff line Loading @@ -486,9 +486,6 @@ class PersonService implements UseOscarConfigurationService, UseEntityManager, U $authPersonNormalize = $this->getOscarConfigurationService()->getAuthPersonNormalize(); /** @var AuthentificationRepository $authentificationRepository */ $authentificationRepository = $this->getEntityManager()->getRepository(Authentification::class); // Liste des personnes ayant des notifications non-lues $persons = $this->getPersonRepository()->getPersonsWithUnreadNotificationsAndAuthentification($authPersonNormalize); Loading @@ -498,7 +495,7 @@ class PersonService implements UseOscarConfigurationService, UseEntityManager, U foreach ($persons as $person) { try { /** @var Authentification $auth */ $auth = $authentificationRepository->getAuthentificationPerson($person, $authPersonNormalize); $auth = $this->getPersonAuthentification($person); $settings = $auth->getSettings(); if (!$settings) { Loading Loading @@ -1924,11 +1921,17 @@ class PersonService implements UseOscarConfigurationService, UseEntityManager, U return $this->getEntityManager()->getRepository(Authentification::class); } /** * @return OrganizationRepository */ public function getOrganizationRepository() { return $this->getEntityManager()->getRepository(Organization::class); } /** * @return RoleRepository */ public function getRoleRepository(): RoleRepository { return $this->getEntityManager()->getRepository(Role::class); Loading