Commit e3aad028 authored by Jean-Philippe Metivier's avatar Jean-Philippe Metivier
Browse files

Application du changement de fonction pour le calcul des responsables

parent db0d853c
Loading
Loading
Loading
Loading
+3 −3
Changes for module/Application/src/Application/Service/Notification/NotificationService.php: 3 added lines, 3 removed lines.
Original line number Diff line number Diff line
@@ -47,9 +47,9 @@ class NotificationService
        $emails = [];
        if ($ficheposte !== null) {
            $agent = $ficheposte->getAgent();
            $responsables = $this->getAgentService()->getResposabiliteStructure($agent);
            foreach ($responsables as $responsable) {
                if ($responsable and $responsable->getAgent()->getEmail()) $emails[] = $responsable->getAgent()->getEmail();
            $responsables = $this->getAgentService()->computeSuperieures($agent);
            foreach ($responsables as $key => $agent) {
                if ($agent and $agent->getEmail()) $emails[] = $agent->getEmail();
            }
        }
        return $emails;