Loading module/These/config/others/co-encadrant.config.php +6 −0 Changes for module/These/config/others/co-encadrant.config.php: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -51,6 +51,7 @@ return [ 'options' => [ 'route' => '/co-encadrant', 'defaults' => [ /** @see CoEncadrantController::indexAction() */ 'controller' => CoEncadrantController::class, 'action' => 'index', ], Loading @@ -62,6 +63,7 @@ return [ 'options' => [ 'route' => '/historique[/:co-encadrant]', 'defaults' => [ /** @see CoEncadrantController::historiqueAction() */ 'controller' => CoEncadrantController::class, 'action' => 'historique', ], Loading @@ -83,6 +85,7 @@ return [ 'options' => [ 'route' => '/generer-export-csv/:structure-type/:structure-id', 'defaults' => [ /** @see CoEncadrantController::genererExportCsvAction() */ 'controller' => CoEncadrantController::class, 'action' => 'generer-export-csv', ], Loading @@ -93,6 +96,7 @@ return [ 'options' => [ 'route' => '/rechercher-co-encadrant', 'defaults' => [ /** @see CoEncadrantController::rechercherCoEncadrantAction() */ 'controller' => CoEncadrantController::class, 'action' => 'rechercher-co-encadrant', ], Loading @@ -103,6 +107,7 @@ return [ 'options' => [ 'route' => '/ajouter-co-encadrant/:these', 'defaults' => [ /** @see CoEncadrantController::ajouterCoEncadrantAction() */ 'controller' => CoEncadrantController::class, 'action' => 'ajouter-co-encadrant', ], Loading @@ -113,6 +118,7 @@ return [ 'options' => [ 'route' => '/retirer-co-encadrant/:these/:co-encadrant', 'defaults' => [ /** @see CoEncadrantController::retirerCoEncadrantAction() */ 'controller' => CoEncadrantController::class, 'action' => 'retirer-co-encadrant', ], Loading module/These/src/These/Controller/CoEncadrantController.php +19 −11 Changes for module/These/src/These/Controller/CoEncadrantController.php: 19 added lines, 11 removed lines. Original line number Diff line number Diff line Loading @@ -13,7 +13,8 @@ use Laminas\Mvc\Controller\AbstractActionController; use Laminas\View\Model\JsonModel; use Laminas\View\Model\ViewModel; use Laminas\View\Renderer\PhpRenderer; use Laminas\View\Resolver\TemplatePathStack; use Mpdf\MpdfException; use RuntimeException; use Structure\Entity\Db\EcoleDoctorale; use Structure\Entity\Db\UniteRecherche; use Structure\Service\EcoleDoctorale\EcoleDoctoraleServiceAwareTrait; Loading Loading @@ -44,13 +45,8 @@ class CoEncadrantController extends AbstractActionController use RenduServiceAwareTrait; /** @var PhpRenderer */ private $renderer; /** * @param PhpRenderer $renderer */ public function setRenderer($renderer) private ?PhpRenderer $renderer = null; public function setRenderer(PhpRenderer $renderer): void { $this->renderer = $renderer; } Loading @@ -59,7 +55,8 @@ class CoEncadrantController extends AbstractActionController { $form = $this->getRechercherCoEncadrantForm(); $form->setAttribute('action', $this->url()->fromRoute('co-encadrant', [], [], true)); //todo !doit remonter un acteur /** @see CoEncadrantController::rechercherCoEncadrantAction() */ $form->setUrlCoEncadrant($this->url()->fromRoute('co-encadrant/rechercher-co-encadrant', [], [], true)); $form->get('bouton')->setLabel("Afficher l'historique de co-encadrement"); Loading @@ -67,6 +64,7 @@ class CoEncadrantController extends AbstractActionController if ($request->isPost()) { $data = $request->getPost(); if ($data['co-encadrant']['id'] !== "") { /** @see CoEncadrantController::historiqueAction() */ $this->redirect()->toRoute('co-encadrant/historique', ['co-encadrant' => $data['co-encadrant']['id']]); } } Loading Loading @@ -198,9 +196,15 @@ class CoEncadrantController extends AbstractActionController } $listing .= "</ul>"; try { $logoCOMUE = $this->etablissementService->fetchEtablissementComue() ? $this->fichierStorageService->getFileForLogoStructure($this->etablissementService->fetchEtablissementComue()->getStructure()) : null; $logoETAB = $coencadrant->getEtablissement() ? $this->fichierStorageService->getFileForLogoStructure($coencadrant->getEtablissement()->getStructure()) : null; } catch (StorageAdapterException $e) { throw new RuntimeException("Un problème est survenu lors de la récupération de logo.", 0, $e); } $logos = [ "COMUE" => $this->etablissementService->fetchEtablissementComue()?$this->fichierStorageService->getFileForLogoStructure($this->etablissementService->fetchEtablissementComue()->getStructure()):null, "ETAB" => $coencadrant->getEtablissement()?$this->fichierStorageService->getFileForLogoStructure($coencadrant->getEtablissement()->getStructure()):null, "COMUE" => $logoCOMUE, "ETAB" => $logoETAB, ]; $rendu = $this->getRenduService()->generateRenduByTemplateCode(PdfTemplates::COENCADREMENTS_JUSTIFICATIF, $vars); Loading @@ -209,6 +213,7 @@ class CoEncadrantController extends AbstractActionController $export = new PdfExporter(); try { $export->getMpdf()->SetMargins(0, 0, 60); //todo passer un header exploitant les logo // $export->setHeaderScript('pdf/header.phtml', null, $logos); Loading @@ -216,6 +221,9 @@ class CoEncadrantController extends AbstractActionController $export->setFooterScriptToNone(); $export->addBodyHtml($corps); return $export->export($filename); } catch (MpdfException $e) { throw new RuntimeException("Un problème est survenu lors de la génération du PDF", 0 , $e); } } public function genererExportCsvAction(): CsvModel Loading module/These/src/These/Form/CoEncadrant/RechercherCoEncadrantForm.php +3 −1 Changes for module/These/src/These/Form/CoEncadrant/RechercherCoEncadrantForm.php: 3 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -7,7 +7,8 @@ use Laminas\Form\Form; use Laminas\InputFilter\Factory; use UnicaenApp\Form\Element\SearchAndSelect; class RechercherCoEncadrantForm extends Form { class RechercherCoEncadrantForm extends Form { private ?string $urlCoEncadrant = null; private ?string $urlEtablissement = null; Loading @@ -17,6 +18,7 @@ class RechercherCoEncadrantForm extends Form { $this->urlCoEncadrant = $urlCoEncadrant; $this->get('co-encadrant')->setAutocompleteSource($this->urlCoEncadrant); } public function setUrlEtablisssement(string $urlEtablissement): void { $this->urlEtablissement = $urlEtablissement; Loading module/These/src/These/Service/CoEncadrant/CoEncadrantServiceFactory.php +2 −1 Changes for module/These/src/These/Service/CoEncadrant/CoEncadrantServiceFactory.php: 2 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -7,7 +7,8 @@ use Interop\Container\ContainerInterface; use Psr\Container\ContainerExceptionInterface; use Psr\Container\NotFoundExceptionInterface; class CoEncadrantServiceFactory { class CoEncadrantServiceFactory { /** * @param ContainerInterface $container Loading module/These/view/these/co-encadrant/partial/table-these.phtml +1 −0 Changes for module/These/view/these/co-encadrant/partial/table-these.phtml: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ use These\Entity\Db\These; <?php echo $these->getAnneeUniv1ereInscription(); ?> </td> <td> <?php /** @see \These\Controller\TheseController::detailIdentiteAction() */ ?> <a href="<?php echo $this->url('these/identite', ['these' => $these->getId()], [], true); ?>"> <span class="icon icon-voir"></span> </a> Loading Loading
module/These/config/others/co-encadrant.config.php +6 −0 Changes for module/These/config/others/co-encadrant.config.php: 6 added lines, 0 removed lines. Original line number Diff line number Diff line Loading @@ -51,6 +51,7 @@ return [ 'options' => [ 'route' => '/co-encadrant', 'defaults' => [ /** @see CoEncadrantController::indexAction() */ 'controller' => CoEncadrantController::class, 'action' => 'index', ], Loading @@ -62,6 +63,7 @@ return [ 'options' => [ 'route' => '/historique[/:co-encadrant]', 'defaults' => [ /** @see CoEncadrantController::historiqueAction() */ 'controller' => CoEncadrantController::class, 'action' => 'historique', ], Loading @@ -83,6 +85,7 @@ return [ 'options' => [ 'route' => '/generer-export-csv/:structure-type/:structure-id', 'defaults' => [ /** @see CoEncadrantController::genererExportCsvAction() */ 'controller' => CoEncadrantController::class, 'action' => 'generer-export-csv', ], Loading @@ -93,6 +96,7 @@ return [ 'options' => [ 'route' => '/rechercher-co-encadrant', 'defaults' => [ /** @see CoEncadrantController::rechercherCoEncadrantAction() */ 'controller' => CoEncadrantController::class, 'action' => 'rechercher-co-encadrant', ], Loading @@ -103,6 +107,7 @@ return [ 'options' => [ 'route' => '/ajouter-co-encadrant/:these', 'defaults' => [ /** @see CoEncadrantController::ajouterCoEncadrantAction() */ 'controller' => CoEncadrantController::class, 'action' => 'ajouter-co-encadrant', ], Loading @@ -113,6 +118,7 @@ return [ 'options' => [ 'route' => '/retirer-co-encadrant/:these/:co-encadrant', 'defaults' => [ /** @see CoEncadrantController::retirerCoEncadrantAction() */ 'controller' => CoEncadrantController::class, 'action' => 'retirer-co-encadrant', ], Loading
module/These/src/These/Controller/CoEncadrantController.php +19 −11 Changes for module/These/src/These/Controller/CoEncadrantController.php: 19 added lines, 11 removed lines. Original line number Diff line number Diff line Loading @@ -13,7 +13,8 @@ use Laminas\Mvc\Controller\AbstractActionController; use Laminas\View\Model\JsonModel; use Laminas\View\Model\ViewModel; use Laminas\View\Renderer\PhpRenderer; use Laminas\View\Resolver\TemplatePathStack; use Mpdf\MpdfException; use RuntimeException; use Structure\Entity\Db\EcoleDoctorale; use Structure\Entity\Db\UniteRecherche; use Structure\Service\EcoleDoctorale\EcoleDoctoraleServiceAwareTrait; Loading Loading @@ -44,13 +45,8 @@ class CoEncadrantController extends AbstractActionController use RenduServiceAwareTrait; /** @var PhpRenderer */ private $renderer; /** * @param PhpRenderer $renderer */ public function setRenderer($renderer) private ?PhpRenderer $renderer = null; public function setRenderer(PhpRenderer $renderer): void { $this->renderer = $renderer; } Loading @@ -59,7 +55,8 @@ class CoEncadrantController extends AbstractActionController { $form = $this->getRechercherCoEncadrantForm(); $form->setAttribute('action', $this->url()->fromRoute('co-encadrant', [], [], true)); //todo !doit remonter un acteur /** @see CoEncadrantController::rechercherCoEncadrantAction() */ $form->setUrlCoEncadrant($this->url()->fromRoute('co-encadrant/rechercher-co-encadrant', [], [], true)); $form->get('bouton')->setLabel("Afficher l'historique de co-encadrement"); Loading @@ -67,6 +64,7 @@ class CoEncadrantController extends AbstractActionController if ($request->isPost()) { $data = $request->getPost(); if ($data['co-encadrant']['id'] !== "") { /** @see CoEncadrantController::historiqueAction() */ $this->redirect()->toRoute('co-encadrant/historique', ['co-encadrant' => $data['co-encadrant']['id']]); } } Loading Loading @@ -198,9 +196,15 @@ class CoEncadrantController extends AbstractActionController } $listing .= "</ul>"; try { $logoCOMUE = $this->etablissementService->fetchEtablissementComue() ? $this->fichierStorageService->getFileForLogoStructure($this->etablissementService->fetchEtablissementComue()->getStructure()) : null; $logoETAB = $coencadrant->getEtablissement() ? $this->fichierStorageService->getFileForLogoStructure($coencadrant->getEtablissement()->getStructure()) : null; } catch (StorageAdapterException $e) { throw new RuntimeException("Un problème est survenu lors de la récupération de logo.", 0, $e); } $logos = [ "COMUE" => $this->etablissementService->fetchEtablissementComue()?$this->fichierStorageService->getFileForLogoStructure($this->etablissementService->fetchEtablissementComue()->getStructure()):null, "ETAB" => $coencadrant->getEtablissement()?$this->fichierStorageService->getFileForLogoStructure($coencadrant->getEtablissement()->getStructure()):null, "COMUE" => $logoCOMUE, "ETAB" => $logoETAB, ]; $rendu = $this->getRenduService()->generateRenduByTemplateCode(PdfTemplates::COENCADREMENTS_JUSTIFICATIF, $vars); Loading @@ -209,6 +213,7 @@ class CoEncadrantController extends AbstractActionController $export = new PdfExporter(); try { $export->getMpdf()->SetMargins(0, 0, 60); //todo passer un header exploitant les logo // $export->setHeaderScript('pdf/header.phtml', null, $logos); Loading @@ -216,6 +221,9 @@ class CoEncadrantController extends AbstractActionController $export->setFooterScriptToNone(); $export->addBodyHtml($corps); return $export->export($filename); } catch (MpdfException $e) { throw new RuntimeException("Un problème est survenu lors de la génération du PDF", 0 , $e); } } public function genererExportCsvAction(): CsvModel Loading
module/These/src/These/Form/CoEncadrant/RechercherCoEncadrantForm.php +3 −1 Changes for module/These/src/These/Form/CoEncadrant/RechercherCoEncadrantForm.php: 3 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -7,7 +7,8 @@ use Laminas\Form\Form; use Laminas\InputFilter\Factory; use UnicaenApp\Form\Element\SearchAndSelect; class RechercherCoEncadrantForm extends Form { class RechercherCoEncadrantForm extends Form { private ?string $urlCoEncadrant = null; private ?string $urlEtablissement = null; Loading @@ -17,6 +18,7 @@ class RechercherCoEncadrantForm extends Form { $this->urlCoEncadrant = $urlCoEncadrant; $this->get('co-encadrant')->setAutocompleteSource($this->urlCoEncadrant); } public function setUrlEtablisssement(string $urlEtablissement): void { $this->urlEtablissement = $urlEtablissement; Loading
module/These/src/These/Service/CoEncadrant/CoEncadrantServiceFactory.php +2 −1 Changes for module/These/src/These/Service/CoEncadrant/CoEncadrantServiceFactory.php: 2 added lines, 1 removed line. Original line number Diff line number Diff line Loading @@ -7,7 +7,8 @@ use Interop\Container\ContainerInterface; use Psr\Container\ContainerExceptionInterface; use Psr\Container\NotFoundExceptionInterface; class CoEncadrantServiceFactory { class CoEncadrantServiceFactory { /** * @param ContainerInterface $container Loading
module/These/view/these/co-encadrant/partial/table-these.phtml +1 −0 Changes for module/These/view/these/co-encadrant/partial/table-these.phtml: 1 added line, 0 removed lines. Original line number Diff line number Diff line Loading @@ -43,6 +43,7 @@ use These\Entity\Db\These; <?php echo $these->getAnneeUniv1ereInscription(); ?> </td> <td> <?php /** @see \These\Controller\TheseController::detailIdentiteAction() */ ?> <a href="<?php echo $this->url('these/identite', ['these' => $these->getId()], [], true); ?>"> <span class="icon icon-voir"></span> </a> Loading