Loading module/Application/config/intervenant.config.php +20 −58 Original line number Diff line number Diff line Loading @@ -10,6 +10,7 @@ use Contrat\Controller\ContratController; use Dossier\Assertion\IntervenantDossierAssertion; use Dossier\Controller\IntervenantDossierController; use Mission\Assertion\OffreEmploiAssertion; use Mission\Controller\OffreEmploiController; use Paiement\Controller\PaiementController; use UnicaenPrivilege\Guard\PrivilegeController; use UnicaenPrivilege\Provider\Rule\PrivilegeRuleProvider; Loading Loading @@ -64,24 +65,7 @@ return [ ], ], ], 'candidature' => [ 'type' => 'Segment', 'options' => [ 'route' => '/:intervenant/candidature', 'defaults' => [ 'action' => 'candidature', ], ], ], 'get-candidatures' => [ 'type' => 'Segment', 'options' => [ 'route' => '/:intervenant/get-candidatures', 'defaults' => [ 'action' => 'get-candidatures', ], ], ], 'voir' => [ 'type' => 'Segment', 'options' => [ Loading Loading @@ -279,17 +263,6 @@ return [ 'resource' => PrivilegeController::getResourceId('Application\Controller\Intervenant', 'index'), 'order' => 1, 'pages' => [ 'candidature' => [ 'label' => "Candidatures", 'title' => "Liste de vos candidatures en cours", 'route' => 'intervenant/candidature', 'paramsInject' => [ 'intervenant', ], 'withtarget' => true, 'resource' => PrivilegeController::getResourceId('Application\Controller\Intervenant', 'candidature'), 'order' => 5, ], 'rechercher' => [ 'label' => " Rechercher", 'title' => "Rechercher un intervenant", Loading Loading @@ -348,12 +321,6 @@ return [ Privileges::INTERVENANT_FICHE, ], ], [ 'controller' => 'Application\Controller\Intervenant', 'action' => ['candidature', 'get-candidatures'], 'privileges' => [Privileges::MISSION_CANDIDATURE_VISUALISATION], 'assertion' => OffreEmploiAssertion::class, ], [ 'controller' => 'Application\Controller\Intervenant', 'action' => ['saisir', 'definir-par-defaut', 'synchronisation', 'synchroniser'], Loading Loading @@ -393,6 +360,8 @@ return [ Privileges::REFERENTIEL_REALISE_VISUALISATION, ], ], ], ], Loading @@ -408,13 +377,6 @@ return [ 'resources' => ['Intervenant'], 'assertion' => Assertion\IntervenantAssertion::class, ], [ 'privileges' => [ Privileges::MISSION_CANDIDATURE_VALIDER, ], 'resources' => ['Intervenant'], 'assertion' => OffreEmploiAssertion::class, ], ], ], ], Loading module/Application/src/Controller/IntervenantController.php +0 −32 Original line number Diff line number Diff line Loading @@ -228,38 +228,6 @@ class IntervenantController extends AbstractController public function candidatureAction () { $intervenant = $this->getEvent()->getParam('intervenant'); $canValiderCandidature = $this->isAllowed($intervenant, Privileges::MISSION_CANDIDATURE_VALIDER); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } return compact('intervenant', 'canValiderCandidature'); } public function getCandidaturesAction () { $intervenant = $this->getEvent()->getParam('intervenant'); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } /** * @var Intervenant $intervenant */ $candidatures = $this->getServiceCandidature()->data(['intervenant' => $intervenant]); return $candidatures; } public function definirParDefautAction () { $intervenant = $this->getEvent()->getParam('intervenant'); Loading module/Mission/config/offre-emploi.config.php +48 −1 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ namespace Mission; use Application\Provider\Privilege\Privileges; use Mission\Assertion\OffreEmploiAssertion; use Mission\Controller\OffreEmploiController; use Mission\Controller\OffreEmploiControllerFactory; use Mission\Service\CandidatureService; Loading @@ -16,6 +17,22 @@ use Mission\Service\OffreEmploiServiceFactory; return [ 'routes' => [ 'intervenant' => [ 'child_routes' => [ 'candidature' => [ 'route' => '/:intervenant/candidature', 'controller' => OffreEmploiController::class, 'action' => 'candidature', ], 'get-candidatures' => [ 'route' => '/:intervenant/get-candidatures', 'controller' => OffreEmploiController::class, 'action' => 'get-candidatures', ], ], ], 'offre-emploi' => [ 'route' => '/offre-emploi', 'controller' => OffreEmploiController::class, Loading Loading @@ -92,6 +109,21 @@ return [ 'navigation' => [ 'intervenant' => [ 'pages' => [ 'candidature' => [ 'label' => "Candidatures", 'title' => "Liste de vos candidatures en cours", 'route' => 'intervenant/candidature', 'paramsInject' => [ 'intervenant', ], 'withtarget' => true, 'resource' => PrivilegeController::getResourceId(OffreEmploiController::class, 'candidature'), 'order' => 5, ], ], ], 'gestion' => [ 'pages' => [ 'offres-emploi' => [ Loading Loading @@ -142,6 +174,13 @@ return [ 'resources' => 'OffreEmploi', 'assertion' => Assertion\OffreEmploiAssertion::class, ], [ 'privileges' => [ Privileges::MISSION_CANDIDATURE_VALIDER, ], 'resources' => ['Intervenant'], 'assertion' => Assertion\OffreEmploiAssertion::class, ], ], Loading Loading @@ -188,6 +227,14 @@ return [ 'roles' => ['guest'], ], [ 'controller' => OffreEmploiController::class, 'action' => ['candidature', 'get-candidatures'], 'privileges' => [Privileges::MISSION_CANDIDATURE_VISUALISATION], 'assertion' => Assertion\OffreEmploiAssertion::class, ], ], 'controllers' => [ Loading module/Mission/src/Controller/OffreEmploiController.php +32 −0 Original line number Diff line number Diff line Loading @@ -272,4 +272,36 @@ class OffreEmploiController extends AbstractController return compact('offreEmploi', 'utilisateur', 'canPostuler'); } public function candidatureAction () { $intervenant = $this->getEvent()->getParam('intervenant'); $canValiderCandidature = $this->isAllowed($intervenant, Privileges::MISSION_CANDIDATURE_VALIDER); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } return compact('intervenant', 'canValiderCandidature'); } public function getCandidaturesAction () { $intervenant = $this->getEvent()->getParam('intervenant'); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } /** * @var Intervenant $intervenant */ $candidatures = $this->getServiceCandidature()->data(['intervenant' => $intervenant]); return $candidatures; } } No newline at end of file module/Application/view/application/intervenant/candidature.phtml→module/Mission/view/mission/offre-emploi/candidature.phtml +0 −0 File moved. View file Loading
module/Application/config/intervenant.config.php +20 −58 Original line number Diff line number Diff line Loading @@ -10,6 +10,7 @@ use Contrat\Controller\ContratController; use Dossier\Assertion\IntervenantDossierAssertion; use Dossier\Controller\IntervenantDossierController; use Mission\Assertion\OffreEmploiAssertion; use Mission\Controller\OffreEmploiController; use Paiement\Controller\PaiementController; use UnicaenPrivilege\Guard\PrivilegeController; use UnicaenPrivilege\Provider\Rule\PrivilegeRuleProvider; Loading Loading @@ -64,24 +65,7 @@ return [ ], ], ], 'candidature' => [ 'type' => 'Segment', 'options' => [ 'route' => '/:intervenant/candidature', 'defaults' => [ 'action' => 'candidature', ], ], ], 'get-candidatures' => [ 'type' => 'Segment', 'options' => [ 'route' => '/:intervenant/get-candidatures', 'defaults' => [ 'action' => 'get-candidatures', ], ], ], 'voir' => [ 'type' => 'Segment', 'options' => [ Loading Loading @@ -279,17 +263,6 @@ return [ 'resource' => PrivilegeController::getResourceId('Application\Controller\Intervenant', 'index'), 'order' => 1, 'pages' => [ 'candidature' => [ 'label' => "Candidatures", 'title' => "Liste de vos candidatures en cours", 'route' => 'intervenant/candidature', 'paramsInject' => [ 'intervenant', ], 'withtarget' => true, 'resource' => PrivilegeController::getResourceId('Application\Controller\Intervenant', 'candidature'), 'order' => 5, ], 'rechercher' => [ 'label' => " Rechercher", 'title' => "Rechercher un intervenant", Loading Loading @@ -348,12 +321,6 @@ return [ Privileges::INTERVENANT_FICHE, ], ], [ 'controller' => 'Application\Controller\Intervenant', 'action' => ['candidature', 'get-candidatures'], 'privileges' => [Privileges::MISSION_CANDIDATURE_VISUALISATION], 'assertion' => OffreEmploiAssertion::class, ], [ 'controller' => 'Application\Controller\Intervenant', 'action' => ['saisir', 'definir-par-defaut', 'synchronisation', 'synchroniser'], Loading Loading @@ -393,6 +360,8 @@ return [ Privileges::REFERENTIEL_REALISE_VISUALISATION, ], ], ], ], Loading @@ -408,13 +377,6 @@ return [ 'resources' => ['Intervenant'], 'assertion' => Assertion\IntervenantAssertion::class, ], [ 'privileges' => [ Privileges::MISSION_CANDIDATURE_VALIDER, ], 'resources' => ['Intervenant'], 'assertion' => OffreEmploiAssertion::class, ], ], ], ], Loading
module/Application/src/Controller/IntervenantController.php +0 −32 Original line number Diff line number Diff line Loading @@ -228,38 +228,6 @@ class IntervenantController extends AbstractController public function candidatureAction () { $intervenant = $this->getEvent()->getParam('intervenant'); $canValiderCandidature = $this->isAllowed($intervenant, Privileges::MISSION_CANDIDATURE_VALIDER); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } return compact('intervenant', 'canValiderCandidature'); } public function getCandidaturesAction () { $intervenant = $this->getEvent()->getParam('intervenant'); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } /** * @var Intervenant $intervenant */ $candidatures = $this->getServiceCandidature()->data(['intervenant' => $intervenant]); return $candidatures; } public function definirParDefautAction () { $intervenant = $this->getEvent()->getParam('intervenant'); Loading
module/Mission/config/offre-emploi.config.php +48 −1 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ namespace Mission; use Application\Provider\Privilege\Privileges; use Mission\Assertion\OffreEmploiAssertion; use Mission\Controller\OffreEmploiController; use Mission\Controller\OffreEmploiControllerFactory; use Mission\Service\CandidatureService; Loading @@ -16,6 +17,22 @@ use Mission\Service\OffreEmploiServiceFactory; return [ 'routes' => [ 'intervenant' => [ 'child_routes' => [ 'candidature' => [ 'route' => '/:intervenant/candidature', 'controller' => OffreEmploiController::class, 'action' => 'candidature', ], 'get-candidatures' => [ 'route' => '/:intervenant/get-candidatures', 'controller' => OffreEmploiController::class, 'action' => 'get-candidatures', ], ], ], 'offre-emploi' => [ 'route' => '/offre-emploi', 'controller' => OffreEmploiController::class, Loading Loading @@ -92,6 +109,21 @@ return [ 'navigation' => [ 'intervenant' => [ 'pages' => [ 'candidature' => [ 'label' => "Candidatures", 'title' => "Liste de vos candidatures en cours", 'route' => 'intervenant/candidature', 'paramsInject' => [ 'intervenant', ], 'withtarget' => true, 'resource' => PrivilegeController::getResourceId(OffreEmploiController::class, 'candidature'), 'order' => 5, ], ], ], 'gestion' => [ 'pages' => [ 'offres-emploi' => [ Loading Loading @@ -142,6 +174,13 @@ return [ 'resources' => 'OffreEmploi', 'assertion' => Assertion\OffreEmploiAssertion::class, ], [ 'privileges' => [ Privileges::MISSION_CANDIDATURE_VALIDER, ], 'resources' => ['Intervenant'], 'assertion' => Assertion\OffreEmploiAssertion::class, ], ], Loading Loading @@ -188,6 +227,14 @@ return [ 'roles' => ['guest'], ], [ 'controller' => OffreEmploiController::class, 'action' => ['candidature', 'get-candidatures'], 'privileges' => [Privileges::MISSION_CANDIDATURE_VISUALISATION], 'assertion' => Assertion\OffreEmploiAssertion::class, ], ], 'controllers' => [ Loading
module/Mission/src/Controller/OffreEmploiController.php +32 −0 Original line number Diff line number Diff line Loading @@ -272,4 +272,36 @@ class OffreEmploiController extends AbstractController return compact('offreEmploi', 'utilisateur', 'canPostuler'); } public function candidatureAction () { $intervenant = $this->getEvent()->getParam('intervenant'); $canValiderCandidature = $this->isAllowed($intervenant, Privileges::MISSION_CANDIDATURE_VALIDER); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } return compact('intervenant', 'canValiderCandidature'); } public function getCandidaturesAction () { $intervenant = $this->getEvent()->getParam('intervenant'); if (!$intervenant) { throw new \LogicException('Intervenant introuvable'); } /** * @var Intervenant $intervenant */ $candidatures = $this->getServiceCandidature()->data(['intervenant' => $intervenant]); return $candidatures; } } No newline at end of file
module/Application/view/application/intervenant/candidature.phtml→module/Mission/view/mission/offre-emploi/candidature.phtml +0 −0 File moved. View file