Loading CHANGELOG.md +1 −0 Original line number Diff line number Diff line Loading @@ -9,6 +9,7 @@ Journal des modifications - Interface de gestion des comptes locaux pour les présidents de jury. - Test d'archivabilité : possibilité de configurer le passage par un proxy. - Correction de l'import forcé de thèse : utilisation du unicaen/db-import pour synchroniser après l'import des données. - Ajout d'un filtre pour l'index des propositions de soutenance (index-structure) 2.1.4 ----- Loading module/Application/src/Application/Entity/Db/Repository/EcoleDoctoraleRepository.php +9 −1 Original line number Diff line number Diff line Loading @@ -10,9 +10,10 @@ use UnicaenApp\Exception\RuntimeException; class EcoleDoctoraleRepository extends DefaultEntityRepository { /** * @param bool $ouverte * @return EcoleDoctorale[] */ public function findAll() public function findAll(bool $ouverte = false) { $qb = $this->createQueryBuilder("ed"); $qb Loading @@ -22,6 +23,13 @@ class EcoleDoctoraleRepository extends DefaultEntityRepository ->addSelect("str, sub, typ") ->orderBy("str.libelle"); if ($ouverte) { $qb = $qb->andWhere('str.ferme = 0') ->leftJoin('str.structureSubstituante', 'substitutionTo') ->andWhere('substitutionTo IS NULL') ->orderBy('str.sigle') ; } $ecoles = $qb->getQuery()->getResult(); return $ecoles; Loading module/Application/src/Application/Entity/Db/Repository/UniteRechercheRepository.php +9 −1 Original line number Diff line number Diff line Loading @@ -10,9 +10,10 @@ class UniteRechercheRepository extends DefaultEntityRepository { /** * @param bool $ouverte * @return UniteRecherche[] */ public function findAll() public function findAll(bool $ouverte = false) { /** @var UniteRecherche[] $unites */ $qb = $this->getEntityManager()->getRepository(UniteRecherche::class)->createQueryBuilder("ur"); Loading @@ -23,6 +24,13 @@ class UniteRechercheRepository extends DefaultEntityRepository ->addSelect("str, sub, typ") ->orderBy("str.libelle"); if ($ouverte) { $qb = $qb->andWhere('str.ferme = 0') ->leftJoin('str.structureSubstituante', 'substitutionTo') ->andWhere('substitutionTo IS NULL') ->orderBy('str.sigle') ; } $unites = $qb->getQuery()->getResult(); return $unites; Loading module/Soutenance/src/Soutenance/Controller/IndexController.php +22 −0 Original line number Diff line number Diff line Loading @@ -6,7 +6,10 @@ use Application\Controller\AbstractController; use Application\Entity\Db\Role; use Application\Entity\Db\These; use Application\Service\Acteur\ActeurServiceAwareTrait; use Application\Service\EcoleDoctorale\EcoleDoctoraleServiceAwareTrait; use Application\Service\Etablissement\EtablissementServiceAwareTrait; use Application\Service\These\TheseServiceAwareTrait; use Application\Service\UniteRecherche\UniteRechercheServiceAwareTrait; use Application\Service\UserContextServiceAwareTrait; use Soutenance\Entity\Membre; use Soutenance\Service\Avis\AvisServiceAwareTrait; Loading @@ -23,6 +26,10 @@ class IndexController extends AbstractController use TheseServiceAwareTrait; use UserContextServiceAwareTrait; use EtablissementServiceAwareTrait; use EcoleDoctoraleServiceAwareTrait; use UniteRechercheServiceAwareTrait; /** * Cette action a pour but de dispatcher vers l'index correspondant au rôle sélectionné */ Loading Loading @@ -122,9 +129,24 @@ class IndexController extends AbstractController $role = $this->userContextService->getSelectedIdentityRole(); $propositions = $this->getPropositionService()->getPropositionsByRole($role); $etablissementId = $this->params()->fromQuery('etablissement'); $ecoleDoctoraleId = $this->params()->fromQuery('ecoledoctorale'); $uniteRechercheId = $this->params()->fromQuery('uniterecherche'); if ($etablissementId != '') $propositions = array_filter($propositions, function($proposition) use ($etablissementId) { return $proposition->getThese()->getEtablissement()->getId() == $etablissementId; }); if ($ecoleDoctoraleId != '') $propositions = array_filter($propositions, function($proposition) use ($ecoleDoctoraleId) { return $proposition->getThese()->getEcoleDoctorale()->getId() == $ecoleDoctoraleId; }); if ($uniteRechercheId != '') $propositions = array_filter($propositions, function($proposition) use ($uniteRechercheId) { return $proposition->getThese()->getUniteRecherche()->getId() == $uniteRechercheId; }); return new ViewModel([ 'propositions' => $propositions, 'role' => $role, 'etablissementId' => $etablissementId, 'ecoleDoctoraleId' => $ecoleDoctoraleId, 'uniteRechercheId' => $uniteRechercheId, 'etablissements' => $this->getEtablissementService()->getRepository()->findAllEtablissementsMembres(), 'ecoles' => $this->getEcoleDoctoraleService()->getRepository()->findAll(true), 'unites' => $this->getUniteRechercheService()->getRepository()->findAll(true), ]); } } No newline at end of file module/Soutenance/src/Soutenance/Controller/IndexControllerFactory.php +12 −2 Original line number Diff line number Diff line Loading @@ -3,13 +3,15 @@ namespace Soutenance\Controller; use Application\Service\Acteur\ActeurService; use Application\Service\EcoleDoctorale\EcoleDoctoraleService; use Application\Service\Etablissement\EtablissementService; use Application\Service\These\TheseService; use Application\Service\UniteRecherche\UniteRechercheService; use Application\Service\UserContextService; use Interop\Container\ContainerInterface; use Soutenance\Service\Avis\AvisService; use Soutenance\Service\EngagementImpartialite\EngagementImpartialiteService; use Soutenance\Service\Proposition\PropositionService; use Zend\Mvc\Controller\ControllerManager; class IndexControllerFactory { Loading @@ -22,26 +24,34 @@ class IndexControllerFactory { /** * @var ActeurService $acteurService * @var AvisService $avisService * @var EcoleDoctoraleService $ecoleDoctoraleService * @var EngagementImpartialiteService $engagementService * @var EtablissementService $etablissementService * @var PropositionService $propositionService * @var TheseService $theseService * @var UniteRechercheService $uniteRechercheService * @var UserContextService $userContextService */ $acteurService = $container->get(ActeurService::class); $avisService = $container->get(AvisService::class); $ecoleDoctoraleService = $container->get(EcoleDoctoraleService::class); $engagementService = $container->get(EngagementImpartialiteService::class); $etablissementService = $container->get(EtablissementService::class); $propositionService = $container->get(PropositionService::class); $theseService = $container->get('TheseService'); $userContextService = $container->get('UserContextService'); $uniteRechercheService = $container->get(UniteRechercheService::class); /** @var IndexController $controller */ $controller = new IndexController(); $controller->setActeurService($acteurService); $controller->setAvisService($avisService); $controller->setEcoleDoctoraleService($ecoleDoctoraleService); $controller->setEngagementImpartialiteService($engagementService); $controller->setEtablissementService($etablissementService); $controller->setPropositionService($propositionService); $controller->setTheseService($theseService); $controller->setUserContextService($userContextService); $controller->setUniteRechercheService($uniteRechercheService); return $controller; } Loading Loading
CHANGELOG.md +1 −0 Original line number Diff line number Diff line Loading @@ -9,6 +9,7 @@ Journal des modifications - Interface de gestion des comptes locaux pour les présidents de jury. - Test d'archivabilité : possibilité de configurer le passage par un proxy. - Correction de l'import forcé de thèse : utilisation du unicaen/db-import pour synchroniser après l'import des données. - Ajout d'un filtre pour l'index des propositions de soutenance (index-structure) 2.1.4 ----- Loading
module/Application/src/Application/Entity/Db/Repository/EcoleDoctoraleRepository.php +9 −1 Original line number Diff line number Diff line Loading @@ -10,9 +10,10 @@ use UnicaenApp\Exception\RuntimeException; class EcoleDoctoraleRepository extends DefaultEntityRepository { /** * @param bool $ouverte * @return EcoleDoctorale[] */ public function findAll() public function findAll(bool $ouverte = false) { $qb = $this->createQueryBuilder("ed"); $qb Loading @@ -22,6 +23,13 @@ class EcoleDoctoraleRepository extends DefaultEntityRepository ->addSelect("str, sub, typ") ->orderBy("str.libelle"); if ($ouverte) { $qb = $qb->andWhere('str.ferme = 0') ->leftJoin('str.structureSubstituante', 'substitutionTo') ->andWhere('substitutionTo IS NULL') ->orderBy('str.sigle') ; } $ecoles = $qb->getQuery()->getResult(); return $ecoles; Loading
module/Application/src/Application/Entity/Db/Repository/UniteRechercheRepository.php +9 −1 Original line number Diff line number Diff line Loading @@ -10,9 +10,10 @@ class UniteRechercheRepository extends DefaultEntityRepository { /** * @param bool $ouverte * @return UniteRecherche[] */ public function findAll() public function findAll(bool $ouverte = false) { /** @var UniteRecherche[] $unites */ $qb = $this->getEntityManager()->getRepository(UniteRecherche::class)->createQueryBuilder("ur"); Loading @@ -23,6 +24,13 @@ class UniteRechercheRepository extends DefaultEntityRepository ->addSelect("str, sub, typ") ->orderBy("str.libelle"); if ($ouverte) { $qb = $qb->andWhere('str.ferme = 0') ->leftJoin('str.structureSubstituante', 'substitutionTo') ->andWhere('substitutionTo IS NULL') ->orderBy('str.sigle') ; } $unites = $qb->getQuery()->getResult(); return $unites; Loading
module/Soutenance/src/Soutenance/Controller/IndexController.php +22 −0 Original line number Diff line number Diff line Loading @@ -6,7 +6,10 @@ use Application\Controller\AbstractController; use Application\Entity\Db\Role; use Application\Entity\Db\These; use Application\Service\Acteur\ActeurServiceAwareTrait; use Application\Service\EcoleDoctorale\EcoleDoctoraleServiceAwareTrait; use Application\Service\Etablissement\EtablissementServiceAwareTrait; use Application\Service\These\TheseServiceAwareTrait; use Application\Service\UniteRecherche\UniteRechercheServiceAwareTrait; use Application\Service\UserContextServiceAwareTrait; use Soutenance\Entity\Membre; use Soutenance\Service\Avis\AvisServiceAwareTrait; Loading @@ -23,6 +26,10 @@ class IndexController extends AbstractController use TheseServiceAwareTrait; use UserContextServiceAwareTrait; use EtablissementServiceAwareTrait; use EcoleDoctoraleServiceAwareTrait; use UniteRechercheServiceAwareTrait; /** * Cette action a pour but de dispatcher vers l'index correspondant au rôle sélectionné */ Loading Loading @@ -122,9 +129,24 @@ class IndexController extends AbstractController $role = $this->userContextService->getSelectedIdentityRole(); $propositions = $this->getPropositionService()->getPropositionsByRole($role); $etablissementId = $this->params()->fromQuery('etablissement'); $ecoleDoctoraleId = $this->params()->fromQuery('ecoledoctorale'); $uniteRechercheId = $this->params()->fromQuery('uniterecherche'); if ($etablissementId != '') $propositions = array_filter($propositions, function($proposition) use ($etablissementId) { return $proposition->getThese()->getEtablissement()->getId() == $etablissementId; }); if ($ecoleDoctoraleId != '') $propositions = array_filter($propositions, function($proposition) use ($ecoleDoctoraleId) { return $proposition->getThese()->getEcoleDoctorale()->getId() == $ecoleDoctoraleId; }); if ($uniteRechercheId != '') $propositions = array_filter($propositions, function($proposition) use ($uniteRechercheId) { return $proposition->getThese()->getUniteRecherche()->getId() == $uniteRechercheId; }); return new ViewModel([ 'propositions' => $propositions, 'role' => $role, 'etablissementId' => $etablissementId, 'ecoleDoctoraleId' => $ecoleDoctoraleId, 'uniteRechercheId' => $uniteRechercheId, 'etablissements' => $this->getEtablissementService()->getRepository()->findAllEtablissementsMembres(), 'ecoles' => $this->getEcoleDoctoraleService()->getRepository()->findAll(true), 'unites' => $this->getUniteRechercheService()->getRepository()->findAll(true), ]); } } No newline at end of file
module/Soutenance/src/Soutenance/Controller/IndexControllerFactory.php +12 −2 Original line number Diff line number Diff line Loading @@ -3,13 +3,15 @@ namespace Soutenance\Controller; use Application\Service\Acteur\ActeurService; use Application\Service\EcoleDoctorale\EcoleDoctoraleService; use Application\Service\Etablissement\EtablissementService; use Application\Service\These\TheseService; use Application\Service\UniteRecherche\UniteRechercheService; use Application\Service\UserContextService; use Interop\Container\ContainerInterface; use Soutenance\Service\Avis\AvisService; use Soutenance\Service\EngagementImpartialite\EngagementImpartialiteService; use Soutenance\Service\Proposition\PropositionService; use Zend\Mvc\Controller\ControllerManager; class IndexControllerFactory { Loading @@ -22,26 +24,34 @@ class IndexControllerFactory { /** * @var ActeurService $acteurService * @var AvisService $avisService * @var EcoleDoctoraleService $ecoleDoctoraleService * @var EngagementImpartialiteService $engagementService * @var EtablissementService $etablissementService * @var PropositionService $propositionService * @var TheseService $theseService * @var UniteRechercheService $uniteRechercheService * @var UserContextService $userContextService */ $acteurService = $container->get(ActeurService::class); $avisService = $container->get(AvisService::class); $ecoleDoctoraleService = $container->get(EcoleDoctoraleService::class); $engagementService = $container->get(EngagementImpartialiteService::class); $etablissementService = $container->get(EtablissementService::class); $propositionService = $container->get(PropositionService::class); $theseService = $container->get('TheseService'); $userContextService = $container->get('UserContextService'); $uniteRechercheService = $container->get(UniteRechercheService::class); /** @var IndexController $controller */ $controller = new IndexController(); $controller->setActeurService($acteurService); $controller->setAvisService($avisService); $controller->setEcoleDoctoraleService($ecoleDoctoraleService); $controller->setEngagementImpartialiteService($engagementService); $controller->setEtablissementService($etablissementService); $controller->setPropositionService($propositionService); $controller->setTheseService($theseService); $controller->setUserContextService($userContextService); $controller->setUniteRechercheService($uniteRechercheService); return $controller; } Loading