Commit 623413aa authored by Bertrand Gauthier's avatar Bertrand Gauthier
Browse files

[FIX] Le template de notification SOUTENANCE_FEU_VERT avait besoin de la...

[FIX] Le template de notification SOUTENANCE_FEU_VERT avait besoin de la variable 'soutenance' (proposition).
parent 7b40416d
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -20,6 +20,7 @@ Journal des modifications
- [FIX] Step-Star : requête de sélection des thèses à envoyer (colonne erronée pour le filtre établissement).
- [FIX] Page de couverture de thèse : l'établissement affiché pour le codir était l'établissement du dernier membre du jury affiché.
- [FIX] ré-attribution du privilège d'accès à l'index des formations pour les formateurs
- [FIX] Le template de notification SOUTENANCE_FEU_VERT avait besoin de la variable 'soutenance' (proposition).

8.1.0
-----
+1 −1
Original line number Diff line number Diff line
@@ -379,7 +379,7 @@ class PresoutenanceController extends AbstractController
        $this->getPropositionService()->update($proposition);

        try {
            $notif = $this->soutenanceNotificationFactory->createNotificationFeuVertSoutenance($these);
            $notif = $this->soutenanceNotificationFactory->createNotificationFeuVertSoutenance($proposition);
            $this->notifierService->trigger($notif);
        } catch (\Notification\Exception\RuntimeException $e) {
            // aucun destinataire, todo : cas à gérer !
+4 −2
Original line number Diff line number Diff line
@@ -469,8 +469,10 @@ class SoutenanceNotificationFactory extends NotificationFactory
        return $notif;
    }

    public function createNotificationFeuVertSoutenance(These $these): Notification
    public function createNotificationFeuVertSoutenance(Proposition $proposition): Notification
    {
        $these = $proposition->getThese();

        $emailsActeurs = $this->emailTheseService->fetchEmailActeursDirects($these);
        $emailsED = $this->emailTheseService->fetchEmailEcoleDoctorale($these);
        $emailsUR = $this->emailTheseService->fetchEmailUniteRecherche($these);
@@ -480,7 +482,7 @@ class SoutenanceNotificationFactory extends NotificationFactory
            throw new RuntimeException("Aucune adresse mail trouvée pour la notification [" . MailTemplates::SOUTENANCE_FEU_VERT . "] la thèse {$these->getId()}");
        }

        $vars = ['these' => $these, 'doctorant' => $these->getDoctorant()];
        $vars = ['soutenance' => $proposition, 'these' => $these, 'doctorant' => $these->getDoctorant()];
        $url = $this->getUrlService()->setVariables($vars);
        $vars['Url'] = $url;