Loading module/Application/config/merged/fiche-metier.config.php +12 −0 Original line number Diff line number Diff line Loading @@ -55,6 +55,7 @@ return [ 'detruire', 'historiser', 'restaurer', 'export', 'editer-libelle', 'editer-missions-principales', Loading Loading @@ -112,6 +113,17 @@ return [ ], 'may_terminate' => true, ], 'export' => [ 'type' => Segment::class, 'options' => [ 'route' => '/export/:id', 'defaults' => [ 'controller' => FicheMetierController::class, 'action' => 'export', ], ], 'may_terminate' => true, ], 'editer' => [ 'type' => Segment::class, 'options' => [ Loading module/Application/config/merged/fiche-poste.config.php +12 −0 Original line number Diff line number Diff line Loading @@ -50,6 +50,7 @@ return [ 'retirer-fiche-metier', 'modifier-fiche-metier', 'selectionner-activite', 'export', ], 'roles' => [ ], Loading Loading @@ -93,6 +94,17 @@ return [ ], ], ], 'export' => [ 'type' => Segment::class, 'may_terminate' => true, 'options' => [ 'route' => '/export/:fiche-poste', 'defaults' => [ 'controller' => FichePosteController::class, 'action' => 'export', ], ], ], 'editer' => [ 'type' => Segment::class, 'may_terminate' => true, Loading module/Application/config/merged/poste.config.php +0 −1 Original line number Diff line number Diff line Loading @@ -12,7 +12,6 @@ use Application\Provider\Privilege\PostePrivileges; use Application\Service\Poste\PosteService; use Application\Service\Poste\PosteServiceFactory; use Application\View\Helper\PosteViewHelper; use Application\View\Helper\PosteViewHelperFactory; use UnicaenAuth\Guard\PrivilegeController; use Zend\Mvc\Router\Http\Literal; use Zend\Mvc\Router\Http\Segment; Loading module/Application/src/Application/Controller/FicheMetier/FicheMetierController.php +18 −0 Original line number Diff line number Diff line Loading @@ -20,12 +20,14 @@ use Application\Form\FicheMetier\LibelleFormAwareTrait; use Application\Form\FicheMetier\MissionsPrincipalesForm; use Application\Form\FicheMetier\MissionsPrincipalesFormAwareTrait; use Application\Service\Activite\ActiviteServiceAwareTrait; use Application\Service\Export\FicheMetier\FicheMetierPdfExporter; use Application\Service\FicheMetier\FicheMetierServiceAwareTrait; use Application\Service\RessourceRh\RessourceRhServiceAwareTrait; use Zend\Form\Element\Select; use Zend\Http\Request; use Zend\Mvc\Controller\AbstractActionController; use Zend\View\Model\ViewModel; use Zend\View\Renderer\PhpRenderer; class FicheMetierController extends AbstractActionController{ /** Traits associé aux services */ Loading Loading @@ -379,4 +381,20 @@ class FicheMetierController extends AbstractActionController{ 'form' => $form, ]); } /** Document pour la signature en présidence */ public function exportAction() { $fiche = $this->getFicheMetierService()->getRequestedFicheMetier($this, 'id'); /* @var PhpRenderer $renderer */ $renderer = $this->getServiceLocator()->get('view_renderer'); $exporter = new FicheMetierPdfExporter($renderer, 'A4'); $exporter->setVars([ 'fiche' => $fiche, ]); $exporter->export('export.pdf'); exit; } } No newline at end of file module/Application/src/Application/Controller/FichePoste/FichePosteController.php +19 −1 Original line number Diff line number Diff line Loading @@ -14,10 +14,12 @@ use Application\Form\FichePosteCreation\FichePosteCreationFormAwareTrait; use Application\Form\SpecificitePoste\SpecificitePosteForm; use Application\Form\SpecificitePoste\SpecificitePosteFormAwareTrait; use Application\Service\Agent\AgentServiceAwareTrait; use Application\Service\Export\FichePoste\FichePostePdfExporter; use Application\Service\FichePoste\FichePosteServiceAwareTrait; use Zend\Http\Request; use Zend\Mvc\Controller\AbstractActionController; use Zend\View\Model\ViewModel; use Zend\View\Renderer\PhpRenderer; class FichePosteController extends AbstractActionController { /** Service **/ Loading Loading @@ -78,7 +80,7 @@ class FichePosteController extends AbstractActionController { public function editerAction() { $fiche = $this->getFichePosteService()->getRequestedFichePoste($this, 'fiche-poste', false); $fiche = $this->getFichePosteService()->getLastFichePoste(); if ($fiche === null) $fiche = $this->getFichePosteService()->getLastFichePoste(); return new ViewModel([ 'fiche' => $fiche, ]); Loading Loading @@ -366,4 +368,20 @@ class FichePosteController extends AbstractActionController { return (new ViewModel(['title' => 'Informations saisies incorrectes']))->setTemplate('layout/flashMessage'); } } /** Document pour la signature en présidence */ public function exportAction() { $fiche = $this->getFichePosteService()->getRequestedFichePoste($this, 'fiche-poste'); /* @var PhpRenderer $renderer */ $renderer = $this->getServiceLocator()->get('view_renderer'); $exporter = new FichePostePdfExporter($renderer, 'A4'); $exporter->setVars([ 'fiche' => $fiche, ]); $exporter->export('export.pdf'); exit; } } No newline at end of file Loading
module/Application/config/merged/fiche-metier.config.php +12 −0 Original line number Diff line number Diff line Loading @@ -55,6 +55,7 @@ return [ 'detruire', 'historiser', 'restaurer', 'export', 'editer-libelle', 'editer-missions-principales', Loading Loading @@ -112,6 +113,17 @@ return [ ], 'may_terminate' => true, ], 'export' => [ 'type' => Segment::class, 'options' => [ 'route' => '/export/:id', 'defaults' => [ 'controller' => FicheMetierController::class, 'action' => 'export', ], ], 'may_terminate' => true, ], 'editer' => [ 'type' => Segment::class, 'options' => [ Loading
module/Application/config/merged/fiche-poste.config.php +12 −0 Original line number Diff line number Diff line Loading @@ -50,6 +50,7 @@ return [ 'retirer-fiche-metier', 'modifier-fiche-metier', 'selectionner-activite', 'export', ], 'roles' => [ ], Loading Loading @@ -93,6 +94,17 @@ return [ ], ], ], 'export' => [ 'type' => Segment::class, 'may_terminate' => true, 'options' => [ 'route' => '/export/:fiche-poste', 'defaults' => [ 'controller' => FichePosteController::class, 'action' => 'export', ], ], ], 'editer' => [ 'type' => Segment::class, 'may_terminate' => true, Loading
module/Application/config/merged/poste.config.php +0 −1 Original line number Diff line number Diff line Loading @@ -12,7 +12,6 @@ use Application\Provider\Privilege\PostePrivileges; use Application\Service\Poste\PosteService; use Application\Service\Poste\PosteServiceFactory; use Application\View\Helper\PosteViewHelper; use Application\View\Helper\PosteViewHelperFactory; use UnicaenAuth\Guard\PrivilegeController; use Zend\Mvc\Router\Http\Literal; use Zend\Mvc\Router\Http\Segment; Loading
module/Application/src/Application/Controller/FicheMetier/FicheMetierController.php +18 −0 Original line number Diff line number Diff line Loading @@ -20,12 +20,14 @@ use Application\Form\FicheMetier\LibelleFormAwareTrait; use Application\Form\FicheMetier\MissionsPrincipalesForm; use Application\Form\FicheMetier\MissionsPrincipalesFormAwareTrait; use Application\Service\Activite\ActiviteServiceAwareTrait; use Application\Service\Export\FicheMetier\FicheMetierPdfExporter; use Application\Service\FicheMetier\FicheMetierServiceAwareTrait; use Application\Service\RessourceRh\RessourceRhServiceAwareTrait; use Zend\Form\Element\Select; use Zend\Http\Request; use Zend\Mvc\Controller\AbstractActionController; use Zend\View\Model\ViewModel; use Zend\View\Renderer\PhpRenderer; class FicheMetierController extends AbstractActionController{ /** Traits associé aux services */ Loading Loading @@ -379,4 +381,20 @@ class FicheMetierController extends AbstractActionController{ 'form' => $form, ]); } /** Document pour la signature en présidence */ public function exportAction() { $fiche = $this->getFicheMetierService()->getRequestedFicheMetier($this, 'id'); /* @var PhpRenderer $renderer */ $renderer = $this->getServiceLocator()->get('view_renderer'); $exporter = new FicheMetierPdfExporter($renderer, 'A4'); $exporter->setVars([ 'fiche' => $fiche, ]); $exporter->export('export.pdf'); exit; } } No newline at end of file
module/Application/src/Application/Controller/FichePoste/FichePosteController.php +19 −1 Original line number Diff line number Diff line Loading @@ -14,10 +14,12 @@ use Application\Form\FichePosteCreation\FichePosteCreationFormAwareTrait; use Application\Form\SpecificitePoste\SpecificitePosteForm; use Application\Form\SpecificitePoste\SpecificitePosteFormAwareTrait; use Application\Service\Agent\AgentServiceAwareTrait; use Application\Service\Export\FichePoste\FichePostePdfExporter; use Application\Service\FichePoste\FichePosteServiceAwareTrait; use Zend\Http\Request; use Zend\Mvc\Controller\AbstractActionController; use Zend\View\Model\ViewModel; use Zend\View\Renderer\PhpRenderer; class FichePosteController extends AbstractActionController { /** Service **/ Loading Loading @@ -78,7 +80,7 @@ class FichePosteController extends AbstractActionController { public function editerAction() { $fiche = $this->getFichePosteService()->getRequestedFichePoste($this, 'fiche-poste', false); $fiche = $this->getFichePosteService()->getLastFichePoste(); if ($fiche === null) $fiche = $this->getFichePosteService()->getLastFichePoste(); return new ViewModel([ 'fiche' => $fiche, ]); Loading Loading @@ -366,4 +368,20 @@ class FichePosteController extends AbstractActionController { return (new ViewModel(['title' => 'Informations saisies incorrectes']))->setTemplate('layout/flashMessage'); } } /** Document pour la signature en présidence */ public function exportAction() { $fiche = $this->getFichePosteService()->getRequestedFichePoste($this, 'fiche-poste'); /* @var PhpRenderer $renderer */ $renderer = $this->getServiceLocator()->get('view_renderer'); $exporter = new FichePostePdfExporter($renderer, 'A4'); $exporter->setVars([ 'fiche' => $fiche, ]); $exporter->export('export.pdf'); exit; } } No newline at end of file