Loading data/privileges.php +1 Viewed Changes for data/privileges.php: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ return [ 'grands-types-diplome-edition' => 'Grands types de diplômes (édition)', 'types-diplome-visualisation' => 'Types de diplômes (visualisation)', 'types-diplome-edition' => 'Types de diplômes (édition)', 'reconduction-offre' => 'Prolongation de l\'offre l\'année suivante', ], ], Loading module/Application/config/aaa_module.config.php +1 Viewed Changes for module/Application/config/aaa_module.config.php: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -153,6 +153,7 @@ $config = [ Service\DepartementService::class => Service\DepartementService::class, Service\FichierService::class => Service\FichierService::class, Service\TauxHoraireHETDService::class => Service\TauxHoraireHETDService::class, Assertion\InformationAssertion::class => Assertion\InformationAssertion::class, ORM\Event\Listeners\HistoriqueListener::class => ORM\Event\Listeners\HistoriqueListener::class, ], 'factories' => [ Loading module/Application/config/administration.config.php +1 Viewed Changes for module/Application/config/administration.config.php: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -68,6 +68,7 @@ return [ Privileges::DOMAINES_FONCTIONNELS_ADMINISTRATION_VISUALISATION, Privileges::MOTIFS_MODIFICATION_SERVICE_DU_VISUALISATION, Privileges::MOTIF_NON_PAIEMENT_VISUALISATION, Privileges::ODF_RECONDUCTION_OFFRE, Privileges::STRUCTURES_ADMINISTRATION_VISUALISATION, ], 'assertion' => Assertion\GestionAssertion::class, Loading module/Application/config/offre-formation.config.php +28 −1 Viewed Changes for module/Application/config/offre-formation.config.php: 28 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -33,6 +33,15 @@ return [ ], ], ], 'reconduction' => [ 'type' => 'Segment', 'options' => [ 'route' => '/reconduction', 'defaults' => [ 'action' => 'reconduction', ], ], ], 'element' => [ 'type' => 'Literal', 'options' => [ Loading Loading @@ -199,6 +208,16 @@ return [ 'route' => 'of', 'resource' => PrivilegeController::getResourceId('Application\Controller\OffreFormation', 'index'), ], 'administration' => [ 'pages' => [ 'reconduction-offre' => [ 'label' => 'Reconduction de l\'offre de formation', 'icon' => 'glyphicon glyphicon-list-alt', 'route' => 'of/reconduction', 'resource' => PrivilegeController::getResourceId('Application\Controller\OffreFormation', 'reconduction'), ], ], ], ], ], ], Loading @@ -217,6 +236,11 @@ return [ 'action' => ['export'], 'privileges' => Privileges::ODF_EXPORT_CSV, ], [ 'controller' => 'Application\Controller\OffreFormation', 'action' => ['reconduction'], 'privileges' => Privileges::ODF_RECONDUCTION_OFFRE, ], /* Etapes */ [ 'controller' => 'Application\Controller\OffreFormation\Etape', Loading Loading @@ -346,9 +370,12 @@ return [ Service\ElementModulateurService::class => Service\ElementModulateurService::class, Service\TypeModulateurService::class => Service\TypeModulateurService::class, Service\DomaineFonctionnelService::class => Service\DomaineFonctionnelService::class, Assertion\OffreDeFormationAssertion::class => Assertion\OffreDeFormationAssertion::class, Service\OffreFormationService::class => Service\OffreFormationService::class, Processus\ReconductionProcessus::class => Processus\ReconductionProcessus::class, ], 'factories' => [ Assertion\OffreDeFormationAssertion::class => \UnicaenAuth\Assertion\AssertionFactory::class, Processus\ReconductionProcessus::class => Processus\Factory\ReconductionProcessusFactory::class, ], ], 'form_elements' => [ Loading module/Application/src/Application/Controller/OffreFormationController.php +118 −99 Viewed Changes for module/Application/src/Application/Controller/OffreFormationController.php: 118 added lines, 99 removed lines. Original line number Diff line number Diff line Loading @@ -7,12 +7,14 @@ use Application\Entity\Db\Etape; use Application\Entity\Db\GroupeTypeFormation; use Application\Entity\Db\TypeFormation; use Application\Entity\Db\TypeModulateur; use Application\Entity\NiveauEtape; use Application\Processus\Traits\ReconductionProcessusAwareTrait; use Application\Service\Traits\AnneeServiceAwareTrait; use Application\Service\Traits\ContextServiceAwareTrait; use Application\Service\Traits\ElementPedagogiqueServiceAwareTrait; use Application\Service\Traits\EtapeServiceAwareTrait; use Application\Service\Traits\LocalContextServiceAwareTrait; use Application\Service\Traits\NiveauEtapeServiceAwareTrait; use Application\Service\Traits\OffreFormationServiceAwareTrait; use Application\Service\Traits\StructureServiceAwareTrait; use UnicaenApp\View\Model\CsvModel; use Zend\Session\Container; Loading @@ -31,6 +33,9 @@ class OffreFormationController extends AbstractController use ElementPedagogiqueServiceAwareTrait; use EtapeServiceAwareTrait; use NiveauEtapeServiceAwareTrait; use AnneeServiceAwareTrait; use ReconductionProcessusAwareTrait; use OffreFormationServiceAwareTrait; /** * @var Container Loading @@ -39,106 +44,12 @@ class OffreFormationController extends AbstractController protected function initFilters() { /* Mise en place des filtres */ $this->em()->getFilters()->enable('historique')->init([ ElementPedagogique::class, TypeFormation::class, GroupeTypeFormation::class, TypeModulateur::class, ]); $this->em()->getFilters()->enable('annee')->init([ ElementPedagogique::class, Etape::class, ]); } protected function getParams() { $structure = $this->context()->structureFromQuery() ?: $this->getServiceContext()->getStructure(); $niveau = $this->context()->niveauFromQuery(); $etape = $this->context()->etapeFromQuery(); if ($niveau) $niveau = $this->getServiceNiveauEtape()->get($niveau); // entité Niveau return [$structure, $niveau, $etape]; } protected function getNeep($structure, $niveau, $etape) { if (!$structure) return [[], [], []]; $niveaux = []; $etapes = []; $elements = []; $query = $this->em()->createQuery('SELECT partial e.{id,code,libelle,sourceCode,niveau,histoDestruction}, partial tf.{id}, partial gtf.{id, libelleCourt, ordre}, partial ep.{id,code,libelle,sourceCode,etape,periode,tauxFoad,fi,fc,fa,tauxFi,tauxFc,tauxFa} FROM Application\Entity\Db\Etape e JOIN e.structure s JOIN e.typeFormation tf JOIN tf.groupe gtf LEFT JOIN e.elementPedagogique ep WHERE s = :structure OR ep.structure = :structure ORDER BY gtf.ordre, e.niveau '); $query->setParameter('structure', $structure); $result = $query->getResult(); foreach ($result as $object) { if ($object instanceof Etape) { $n = NiveauEtape::getInstanceFromEtape($object); if ($object->estNonHistorise()) { $niveaux[$n->getId()] = $n; } if (!$niveau || $niveau->getId() == $n->getId()) { if ($object->estNonHistorise() || $object->getElementPedagogique()->count() > 0){ $etapes[] = $object; } if (!$etape || $etape === $object) { foreach ($object->getElementPedagogique() as $ep) { $elements[$ep->getId()] = $ep; } } } } } /* Tris */ uasort($etapes, function (Etape $e1, Etape $e2) { $e1Lib = ($e1->getElementPedagogique()->isEmpty() ? 'a_' : 'z_') . strtolower(trim($e1->getLibelle())); $e2Lib = ($e2->getElementPedagogique()->isEmpty() ? 'a_' : 'z_') . strtolower(trim($e2->getLibelle())); return $e1Lib > $e2Lib; }); uasort($elements, function (ElementPedagogique $e1, ElementPedagogique $e2) { $e1Lib = strtolower(trim($e1->getEtape()->getLibelle() . ' ' . $e1->getLibelle())); $e2Lib = strtolower(trim($e2->getEtape()->getLibelle() . ' ' . $e2->getLibelle())); return $e1Lib > $e2Lib; }); return [$niveaux, $etapes, $elements]; } public function indexAction() { $this->initFilters(); list($structure, $niveau, $etape) = $this->getParams(); [$structure, $niveau, $etape] = $this->getParams(); // persiste les filtres dans le contexte local $this->getServiceLocalContext() Loading @@ -147,7 +58,7 @@ class OffreFormationController extends AbstractController ->setEtape($etape); $structures = $this->getServiceStructure()->getList($this->getServiceStructure()->finderByEnseignement()); list($niveaux, $etapes, $elements) = $this->getNeep($structure, $niveau, $etape); [$niveaux, $etapes, $elements] = $this->getServiceOffreFormation()->getNeep($structure, $niveau, $etape); $params = []; if ($structure) $params['structure'] = $structure->getId(); Loading Loading @@ -179,9 +90,9 @@ class OffreFormationController extends AbstractController { $this->initFilters(); list($structure, $niveau, $etape) = $this->getParams(); [$structure, $niveau, $etape] = $this->getParams(); $elements = $this->getNeep($structure, $niveau, $etape)[2]; $elements = $this->getServiceOffreFormation()->getNeep($structure, $niveau, $etape)[2]; /* @var $elements ElementPedagogique[] */ $csvModel = new CsvModel(); Loading Loading @@ -229,4 +140,112 @@ class OffreFormationController extends AbstractController return $csvModel; } public function reconductionAction() { $this->initFilterHistorique(); [$structure, $niveau, $etape] = $this->getParams(); //Get role of user $role = $this->getServiceContext()->getSelectedIdentityRole(); $qb = $this->getServiceStructure()->finderByHistorique(); $this->getServiceStructure()->finderByEnseignement($qb); $this->getServiceStructure()->finderByRole($role, $qb); $structures = $this->getServiceStructure()->getList($qb); $anneeEnCours = $this->getServiceContext()->getAnnee(); [$offresComplementaires, $mappingEtape, $reconductionTotale] = $this->getServiceOffreFormation()->getOffreComplementaire($structure, $niveau, $etape); $reconductionStep = ''; $messageStep = ''; $fromPost = false; $request = $this->getRequest(); if ($request->isPost()) { $datas = $request->getPost(); $fromPost = true; //Ajout du mapping des EtapesN et EtapesN1 pour pouvoir reconduire un element pédagogique sur une etape déjà reconduite. $datas['mappingEtape'] = $mappingEtape; $reconductionProcessus = $this->getProcessusReconduction(); try { //Disable filter historique pour regarder si étape ou element avec date de desctruction $this->disableFilters('historique'); if ($reconductionProcessus->reconduction($datas)) { $this->flashMessenger()->addSuccessMessage("Les éléments ont bien été reconduits pour l'année universitaire prochaine."); } else { $this->flashMessenger()->addErrorMessage("Les éléments n'ont pas pu être reconduits. Merci de contacter le support."); } } catch (\Exception $e) { $reconductionStep = false; $messageStep = $e->getMessage(); $this->flashMessenger()->addErrorMessage($e->getMessage()); } } return [ 'fromPost' => $fromPost, 'offresComplementaires' => $offresComplementaires, 'reconductionTotale' => $reconductionTotale, 'structure' => $structure, 'structures' => $structures, 'anneeEnCours' => $anneeEnCours, 'reconductionStep' => $reconductionStep, 'messageStep' => $messageStep, ]; } protected function initFilters() { $this->initFilterAnnee(); $this->initFilterHistorique(); } protected function initFilterAnnee() { $this->em()->getFilters()->enable('annee')->init([ ElementPedagogique::class, Etape::class, ]); } protected function initFilterHistorique() { /* Mise en place des filtres */ $this->em()->getFilters()->enable('historique')->init([ ElementPedagogique::class, TypeFormation::class, GroupeTypeFormation::class, TypeModulateur::class, ]); } protected function disableFilters($name) { $this->em()->getFilters()->disable($name); } protected function getParams() { $structure = $this->context()->structureFromQuery() ?: $this->getServiceContext()->getStructure(); $niveau = $this->context()->niveauFromQuery(); $etape = $this->context()->etapeFromQuery(); if ($niveau) $niveau = $this->getServiceNiveauEtape()->get($niveau); // entité Niveau return [$structure, $niveau, $etape]; } } Loading
data/privileges.php +1 Viewed Changes for data/privileges.php: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -19,6 +19,7 @@ return [ 'grands-types-diplome-edition' => 'Grands types de diplômes (édition)', 'types-diplome-visualisation' => 'Types de diplômes (visualisation)', 'types-diplome-edition' => 'Types de diplômes (édition)', 'reconduction-offre' => 'Prolongation de l\'offre l\'année suivante', ], ], Loading
module/Application/config/aaa_module.config.php +1 Viewed Changes for module/Application/config/aaa_module.config.php: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -153,6 +153,7 @@ $config = [ Service\DepartementService::class => Service\DepartementService::class, Service\FichierService::class => Service\FichierService::class, Service\TauxHoraireHETDService::class => Service\TauxHoraireHETDService::class, Assertion\InformationAssertion::class => Assertion\InformationAssertion::class, ORM\Event\Listeners\HistoriqueListener::class => ORM\Event\Listeners\HistoriqueListener::class, ], 'factories' => [ Loading
module/Application/config/administration.config.php +1 Viewed Changes for module/Application/config/administration.config.php: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -68,6 +68,7 @@ return [ Privileges::DOMAINES_FONCTIONNELS_ADMINISTRATION_VISUALISATION, Privileges::MOTIFS_MODIFICATION_SERVICE_DU_VISUALISATION, Privileges::MOTIF_NON_PAIEMENT_VISUALISATION, Privileges::ODF_RECONDUCTION_OFFRE, Privileges::STRUCTURES_ADMINISTRATION_VISUALISATION, ], 'assertion' => Assertion\GestionAssertion::class, Loading
module/Application/config/offre-formation.config.php +28 −1 Viewed Changes for module/Application/config/offre-formation.config.php: 28 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -33,6 +33,15 @@ return [ ], ], ], 'reconduction' => [ 'type' => 'Segment', 'options' => [ 'route' => '/reconduction', 'defaults' => [ 'action' => 'reconduction', ], ], ], 'element' => [ 'type' => 'Literal', 'options' => [ Loading Loading @@ -199,6 +208,16 @@ return [ 'route' => 'of', 'resource' => PrivilegeController::getResourceId('Application\Controller\OffreFormation', 'index'), ], 'administration' => [ 'pages' => [ 'reconduction-offre' => [ 'label' => 'Reconduction de l\'offre de formation', 'icon' => 'glyphicon glyphicon-list-alt', 'route' => 'of/reconduction', 'resource' => PrivilegeController::getResourceId('Application\Controller\OffreFormation', 'reconduction'), ], ], ], ], ], ], Loading @@ -217,6 +236,11 @@ return [ 'action' => ['export'], 'privileges' => Privileges::ODF_EXPORT_CSV, ], [ 'controller' => 'Application\Controller\OffreFormation', 'action' => ['reconduction'], 'privileges' => Privileges::ODF_RECONDUCTION_OFFRE, ], /* Etapes */ [ 'controller' => 'Application\Controller\OffreFormation\Etape', Loading Loading @@ -346,9 +370,12 @@ return [ Service\ElementModulateurService::class => Service\ElementModulateurService::class, Service\TypeModulateurService::class => Service\TypeModulateurService::class, Service\DomaineFonctionnelService::class => Service\DomaineFonctionnelService::class, Assertion\OffreDeFormationAssertion::class => Assertion\OffreDeFormationAssertion::class, Service\OffreFormationService::class => Service\OffreFormationService::class, Processus\ReconductionProcessus::class => Processus\ReconductionProcessus::class, ], 'factories' => [ Assertion\OffreDeFormationAssertion::class => \UnicaenAuth\Assertion\AssertionFactory::class, Processus\ReconductionProcessus::class => Processus\Factory\ReconductionProcessusFactory::class, ], ], 'form_elements' => [ Loading
module/Application/src/Application/Controller/OffreFormationController.php +118 −99 Viewed Changes for module/Application/src/Application/Controller/OffreFormationController.php: 118 added lines, 99 removed lines. Original line number Diff line number Diff line Loading @@ -7,12 +7,14 @@ use Application\Entity\Db\Etape; use Application\Entity\Db\GroupeTypeFormation; use Application\Entity\Db\TypeFormation; use Application\Entity\Db\TypeModulateur; use Application\Entity\NiveauEtape; use Application\Processus\Traits\ReconductionProcessusAwareTrait; use Application\Service\Traits\AnneeServiceAwareTrait; use Application\Service\Traits\ContextServiceAwareTrait; use Application\Service\Traits\ElementPedagogiqueServiceAwareTrait; use Application\Service\Traits\EtapeServiceAwareTrait; use Application\Service\Traits\LocalContextServiceAwareTrait; use Application\Service\Traits\NiveauEtapeServiceAwareTrait; use Application\Service\Traits\OffreFormationServiceAwareTrait; use Application\Service\Traits\StructureServiceAwareTrait; use UnicaenApp\View\Model\CsvModel; use Zend\Session\Container; Loading @@ -31,6 +33,9 @@ class OffreFormationController extends AbstractController use ElementPedagogiqueServiceAwareTrait; use EtapeServiceAwareTrait; use NiveauEtapeServiceAwareTrait; use AnneeServiceAwareTrait; use ReconductionProcessusAwareTrait; use OffreFormationServiceAwareTrait; /** * @var Container Loading @@ -39,106 +44,12 @@ class OffreFormationController extends AbstractController protected function initFilters() { /* Mise en place des filtres */ $this->em()->getFilters()->enable('historique')->init([ ElementPedagogique::class, TypeFormation::class, GroupeTypeFormation::class, TypeModulateur::class, ]); $this->em()->getFilters()->enable('annee')->init([ ElementPedagogique::class, Etape::class, ]); } protected function getParams() { $structure = $this->context()->structureFromQuery() ?: $this->getServiceContext()->getStructure(); $niveau = $this->context()->niveauFromQuery(); $etape = $this->context()->etapeFromQuery(); if ($niveau) $niveau = $this->getServiceNiveauEtape()->get($niveau); // entité Niveau return [$structure, $niveau, $etape]; } protected function getNeep($structure, $niveau, $etape) { if (!$structure) return [[], [], []]; $niveaux = []; $etapes = []; $elements = []; $query = $this->em()->createQuery('SELECT partial e.{id,code,libelle,sourceCode,niveau,histoDestruction}, partial tf.{id}, partial gtf.{id, libelleCourt, ordre}, partial ep.{id,code,libelle,sourceCode,etape,periode,tauxFoad,fi,fc,fa,tauxFi,tauxFc,tauxFa} FROM Application\Entity\Db\Etape e JOIN e.structure s JOIN e.typeFormation tf JOIN tf.groupe gtf LEFT JOIN e.elementPedagogique ep WHERE s = :structure OR ep.structure = :structure ORDER BY gtf.ordre, e.niveau '); $query->setParameter('structure', $structure); $result = $query->getResult(); foreach ($result as $object) { if ($object instanceof Etape) { $n = NiveauEtape::getInstanceFromEtape($object); if ($object->estNonHistorise()) { $niveaux[$n->getId()] = $n; } if (!$niveau || $niveau->getId() == $n->getId()) { if ($object->estNonHistorise() || $object->getElementPedagogique()->count() > 0){ $etapes[] = $object; } if (!$etape || $etape === $object) { foreach ($object->getElementPedagogique() as $ep) { $elements[$ep->getId()] = $ep; } } } } } /* Tris */ uasort($etapes, function (Etape $e1, Etape $e2) { $e1Lib = ($e1->getElementPedagogique()->isEmpty() ? 'a_' : 'z_') . strtolower(trim($e1->getLibelle())); $e2Lib = ($e2->getElementPedagogique()->isEmpty() ? 'a_' : 'z_') . strtolower(trim($e2->getLibelle())); return $e1Lib > $e2Lib; }); uasort($elements, function (ElementPedagogique $e1, ElementPedagogique $e2) { $e1Lib = strtolower(trim($e1->getEtape()->getLibelle() . ' ' . $e1->getLibelle())); $e2Lib = strtolower(trim($e2->getEtape()->getLibelle() . ' ' . $e2->getLibelle())); return $e1Lib > $e2Lib; }); return [$niveaux, $etapes, $elements]; } public function indexAction() { $this->initFilters(); list($structure, $niveau, $etape) = $this->getParams(); [$structure, $niveau, $etape] = $this->getParams(); // persiste les filtres dans le contexte local $this->getServiceLocalContext() Loading @@ -147,7 +58,7 @@ class OffreFormationController extends AbstractController ->setEtape($etape); $structures = $this->getServiceStructure()->getList($this->getServiceStructure()->finderByEnseignement()); list($niveaux, $etapes, $elements) = $this->getNeep($structure, $niveau, $etape); [$niveaux, $etapes, $elements] = $this->getServiceOffreFormation()->getNeep($structure, $niveau, $etape); $params = []; if ($structure) $params['structure'] = $structure->getId(); Loading Loading @@ -179,9 +90,9 @@ class OffreFormationController extends AbstractController { $this->initFilters(); list($structure, $niveau, $etape) = $this->getParams(); [$structure, $niveau, $etape] = $this->getParams(); $elements = $this->getNeep($structure, $niveau, $etape)[2]; $elements = $this->getServiceOffreFormation()->getNeep($structure, $niveau, $etape)[2]; /* @var $elements ElementPedagogique[] */ $csvModel = new CsvModel(); Loading Loading @@ -229,4 +140,112 @@ class OffreFormationController extends AbstractController return $csvModel; } public function reconductionAction() { $this->initFilterHistorique(); [$structure, $niveau, $etape] = $this->getParams(); //Get role of user $role = $this->getServiceContext()->getSelectedIdentityRole(); $qb = $this->getServiceStructure()->finderByHistorique(); $this->getServiceStructure()->finderByEnseignement($qb); $this->getServiceStructure()->finderByRole($role, $qb); $structures = $this->getServiceStructure()->getList($qb); $anneeEnCours = $this->getServiceContext()->getAnnee(); [$offresComplementaires, $mappingEtape, $reconductionTotale] = $this->getServiceOffreFormation()->getOffreComplementaire($structure, $niveau, $etape); $reconductionStep = ''; $messageStep = ''; $fromPost = false; $request = $this->getRequest(); if ($request->isPost()) { $datas = $request->getPost(); $fromPost = true; //Ajout du mapping des EtapesN et EtapesN1 pour pouvoir reconduire un element pédagogique sur une etape déjà reconduite. $datas['mappingEtape'] = $mappingEtape; $reconductionProcessus = $this->getProcessusReconduction(); try { //Disable filter historique pour regarder si étape ou element avec date de desctruction $this->disableFilters('historique'); if ($reconductionProcessus->reconduction($datas)) { $this->flashMessenger()->addSuccessMessage("Les éléments ont bien été reconduits pour l'année universitaire prochaine."); } else { $this->flashMessenger()->addErrorMessage("Les éléments n'ont pas pu être reconduits. Merci de contacter le support."); } } catch (\Exception $e) { $reconductionStep = false; $messageStep = $e->getMessage(); $this->flashMessenger()->addErrorMessage($e->getMessage()); } } return [ 'fromPost' => $fromPost, 'offresComplementaires' => $offresComplementaires, 'reconductionTotale' => $reconductionTotale, 'structure' => $structure, 'structures' => $structures, 'anneeEnCours' => $anneeEnCours, 'reconductionStep' => $reconductionStep, 'messageStep' => $messageStep, ]; } protected function initFilters() { $this->initFilterAnnee(); $this->initFilterHistorique(); } protected function initFilterAnnee() { $this->em()->getFilters()->enable('annee')->init([ ElementPedagogique::class, Etape::class, ]); } protected function initFilterHistorique() { /* Mise en place des filtres */ $this->em()->getFilters()->enable('historique')->init([ ElementPedagogique::class, TypeFormation::class, GroupeTypeFormation::class, TypeModulateur::class, ]); } protected function disableFilters($name) { $this->em()->getFilters()->disable($name); } protected function getParams() { $structure = $this->context()->structureFromQuery() ?: $this->getServiceContext()->getStructure(); $niveau = $this->context()->niveauFromQuery(); $etape = $this->context()->etapeFromQuery(); if ($niveau) $niveau = $this->getServiceNiveauEtape()->get($niveau); // entité Niveau return [$structure, $niveau, $etape]; } }