Commit 91050a4f authored by Laurent Lécluse's avatar Laurent Lécluse
Browse files

Refactoring nom des services : finalisation

parent c0b94769
......@@ -12,7 +12,7 @@ use Application\Entity\Db\Intervenant;
use Application\Service\WorkflowService;
/** @var WorkflowService $w */
$w = $sl->get('workflow');
$w = $sl->get(WorkflowService::class);
$i = new Intervenant();
......
......@@ -7,10 +7,11 @@
* @var $sl \Zend\ServiceManager\ServiceLocatorInterface
*/
use Application\Service\ElementPedagogiqueService;
use Application\Service\IntervenantService;
use Application\Service\PlafondService;
$sl->get('applicationelementpedagogique')->getEntityManager()->getFilters()->enable('historique')->init([
$sl->get(ElementPedagogiqueService::class)->getEntityManager()->getFilters()->enable('historique')->init([
\Application\Entity\Db\VolumeHoraireEns::class,
]);
......
......@@ -105,11 +105,6 @@ class Module implements ConsoleUsageProviderInterface, ConsoleBannerProviderInte
return $serviceLocator->get($serviceName);
}
$serviceName = 'Application' . ucfirst($paramName);
if ($serviceLocator->has($serviceName)) {
return $serviceLocator->get($serviceName);
}
return null;
}
......
This diff is collapsed.
......@@ -3,6 +3,7 @@
namespace Application;
use Application\Mouchard\MouchardCompleterContextFactory;
use Application\Provider\Role\RoleProvider;
use UnicaenAuth\Provider\Rule\PrivilegeRuleProvider;
return [
......@@ -72,8 +73,7 @@ return [
'options' => [
'route' => '/application',
'defaults' => [
'__NAMESPACE__' => 'Application\Controller',
'controller' => 'Index',
'controller' => 'Application\Controller\Index',
'action' => 'index',
],
],
......@@ -95,10 +95,10 @@ return [
],
],
'bjyauthorize' => [
'identity_provider' => 'ApplicationIdentityProvider',
'identity_provider' => Provider\Identity\IdentityProvider::class,
'role_providers' => [
'ApplicationRoleProvider' => [
Provider\Role\RoleProvider::class => [
Acl\Role::class,
],
],
......@@ -122,7 +122,7 @@ return [
[
'roles' => ['user'],
'resources' => 'Information',
'assertion' => 'assertionInformation',
'assertion' => Assertion\InformationAssertion::class,
],
],
],
......@@ -130,27 +130,26 @@ return [
],
'service_manager' => [
'invokables' => [
Service\AnneeService::class => Service\AnneeService::class,
Service\ContextService::class => Service\ContextService::class,
'ApplicationLocalContext' => Service\LocalContext::class,
'ApplicationParametres' => Service\Parametres::class,
'ApplicationUtilisateur' => Service\Utilisateur::class,
'ApplicationTypeIntervention' => Service\TypeIntervention::class,
Service\SourceService::class => Service\SourceService::class,
Service\AffectationService::class => Service\AffectationService::class,
'ApplicationRole' => Service\Role::class,
'ApplicationPays' => Service\Pays::class,
'ApplicationDepartement' => Service\Departement::class,
'applicationFichier' => Service\FichierService::class,
'applicationTauxHoraireHETD' => Service\TauxHoraireHETDService::class,
'dbEvent' => Service\DbEventService::class,
'UnicaenAuth\Service\Privilege' => Service\PrivilegeService::class,
'assertionInformation' => Assertion\InformationAssertion::class,
Service\AnneeService::class => Service\AnneeService::class,
Service\ContextService::class => Service\ContextService::class,
Service\LocalContextService::class => Service\LocalContextService::class,
Service\ParametresService::class => Service\ParametresService::class,
Service\UtilisateurService::class => Service\UtilisateurService::class,
Service\TypeInterventionService::class => Service\TypeInterventionService::class,
Service\SourceService::class => Service\SourceService::class,
Service\AffectationService::class => Service\AffectationService::class,
Service\RoleService::class => Service\RoleService::class,
Service\PaysService::class => Service\PaysService::class,
Service\DepartementService::class => Service\DepartementService::class,
Service\FichierService::class => Service\FichierService::class,
Service\TauxHoraireHETDService::class => Service\TauxHoraireHETDService::class,
'UnicaenAuth\Service\Privilege' => Service\PrivilegeService::class,
Assertion\InformationAssertion::class => Assertion\InformationAssertion::class,
],
'factories' => [
'navigation' => Service\NavigationFactoryFactory::class,
'ApplicationRoleProvider' => Provider\Role\RoleProviderFactory::class,
'ApplicationIdentityProvider' => Provider\Identity\IdentityProviderFactory::class,
Provider\Role\RoleProvider::class => Provider\Role\RoleProviderFactory::class,
Provider\Identity\IdentityProvider::class => Provider\Identity\IdentityProviderFactory::class,
'MouchardCompleterContext' => MouchardCompleterContextFactory::class,
],
],
......
......@@ -13,8 +13,7 @@ return [
'options' => [
'route' => '/administration',
'defaults' => [
'__NAMESPACE__' => 'Application\Controller',
'controller' => 'Administration',
'controller' => 'Application\Controller\Administration',
'action' => 'index',
],
],
......@@ -60,7 +59,7 @@ return [
Privileges::PIECE_JUSTIFICATIVE_GESTION_VISUALISATION,
Privileges::PLAFONDS_GESTION_VISUALISATION,
],
'assertion' => 'AssertionGestion',
'assertion' => Assertion\GestionAssertion::class,
],
],
],
......
......@@ -20,7 +20,7 @@ return [
'intervenant' => '[0-9]*',
],
'defaults' => [
'controller' => 'Agrement',
'controller' => 'Application\Controller\Agrement',
'action' => 'index',
],
],
......@@ -106,7 +106,7 @@ return [
'options' => [
'route' => '/agrement',
'defaults' => [
'controller' => 'Agrement',
'controller' => 'Application\Controller\Agrement',
'action' => 'index',
],
],
......@@ -162,7 +162,7 @@ return [
],
'withtarget' => true,
'resource' => PrivilegeController::getResourceId('Application\Controller\Agrement', 'lister'),
'visible' => 'AssertionAgrement',
'visible' => Assertion\InformationAssertion::class,
'order' => 10,
],
'agrement-conseil-academique' => [
......@@ -174,7 +174,7 @@ return [
],
'withtarget' => true,
'resource' => PrivilegeController::getResourceId('Application\Controller\Agrement', 'lister'),
'visible' => 'AssertionAgrement',
'visible' => Assertion\InformationAssertion::class,
'order' => 11,
],
],
......@@ -187,7 +187,7 @@ return [
'icon' => 'fa fa-tags',
'route' => 'gestion/agrement',
'resource' => PrivilegeController::getResourceId('Application\Controller\Agrement', 'index'),
'visible' => 'AssertionAgrement',
'visible' => Assertion\InformationAssertion::class,
'order' => 50,
'border-color' => '#E1AC5A',
'pages' => [
......@@ -197,7 +197,7 @@ return [
'title' => 'Conseil restreint',
'route' => 'gestion/agrement/conseil-restreint',
'resource' => PrivilegeController::getResourceId('Application\Controller\Agrement', 'saisir-lot'),
'visible' => 'AssertionAgrement',
'visible' => Assertion\InformationAssertion::class,
],
'conseil-academique' => [
'label' => 'Conseil académique',
......@@ -205,7 +205,7 @@ return [
'title' => 'Conseil académique',
'route' => 'gestion/agrement/conseil-academique',
'resource' => PrivilegeController::getResourceId('Application\Controller\Agrement', 'saisir-lot'),
'visible' => 'AssertionAgrement',
'visible' => Assertion\InformationAssertion::class,
],
'export-csv' => [
'label' => 'Export CSV',
......@@ -232,7 +232,7 @@ return [
Privileges::AGREMENT_CONSEIL_ACADEMIQUE_VISUALISATION,
Privileges::AGREMENT_CONSEIL_RESTREINT_VISUALISATION,
],
'assertion' => 'AssertionAgrement',
'assertion' => Assertion\InformationAssertion::class,
],
[
'controller' => 'Application\Controller\Agrement',
......@@ -243,7 +243,7 @@ return [
Privileges::AGREMENT_CONSEIL_ACADEMIQUE_EDITION,
Privileges::AGREMENT_CONSEIL_RESTREINT_EDITION,
],
'assertion' => 'AssertionAgrement',
'assertion' => Assertion\InformationAssertion::class,
],
[
'controller' => 'Application\Controller\Agrement',
......@@ -259,14 +259,14 @@ return [
Privileges::AGREMENT_CONSEIL_ACADEMIQUE_SUPPRESSION,
Privileges::AGREMENT_CONSEIL_RESTREINT_SUPPRESSION,
],
'assertion' => 'AssertionAgrement',
'assertion' => Assertion\InformationAssertion::class,
],
],
],
'resource_providers' => [
'BjyAuthorize\Provider\Resource\Config' => [
'Agrement' => [],
'TblAgrement' => [],
'Agrement' => [],
'TblAgrement' => [],
],
],
'rule_providers' => [
......@@ -280,7 +280,7 @@ return [
Privileges::AGREMENT_CONSEIL_RESTREINT_SUPPRESSION,
],
'resources' => ['TblAgrement', 'Agrement', 'Structure'],
'assertion' => 'AssertionAgrement',
'assertion' => Assertion\InformationAssertion::class,
],
],
],
......@@ -293,11 +293,11 @@ return [
],
'service_manager' => [
'invokables' => [
Service\AgrementService::class => Service\AgrementService::class,
'ApplicationTblAgrement' => Service\TblAgrementService::class,
'ApplicationTypeAgrement' => Service\TypeAgrementService::class,
'ApplicationTypeAgrementStatut' => Service\TypeAgrementStatut::class,
'AssertionAgrement' => Assertion\AgrementAssertion::class,
Service\AgrementService::class => Service\AgrementService::class,
Service\TblAgrementService::class => Service\TblAgrementService::class,
Service\TypeAgrementService::class => Service\TypeAgrementService::class,
Service\TypeAgrementStatutService::class => Service\TypeAgrementStatutService::class,
Assertion\InformationAssertion::class => Assertion\AgrementAssertion::class,
],
],
'view_helpers' => [
......@@ -307,7 +307,7 @@ return [
],
'form_elements' => [
'invokables' => [
'AgrementSaisieForm' => Form\Agrement\Saisie::class,
Form\Agrement\Saisie::class => Form\Agrement\Saisie::class,
],
],
];
......@@ -15,13 +15,12 @@ return [
'options' => [
'route' => '/budget',
'defaults' => [
'__NAMESPACE__' => 'Application\Controller',
'controller' => 'Budget',
'controller' => 'Application\Controller\Budget',
'action' => 'index',
],
],
'child_routes' => [
'engagements-liquidation' => [
'engagements-liquidation' => [
'type' => 'Segment',
'may_terminate' => true,
'options' => [
......@@ -34,7 +33,7 @@ return [
],
],
],
'tableau-de-bord' => [
'tableau-de-bord' => [
'type' => 'Literal',
'may_terminate' => true,
'options' => [
......@@ -44,7 +43,7 @@ return [
],
],
],
'export' => [
'export' => [
'type' => 'Segment',
'may_terminate' => true,
'options' => [
......@@ -57,7 +56,7 @@ return [
],
],
],
'get-json' => [
'get-json' => [
'type' => 'Segment',
'may_terminate' => true,
'options' => [
......@@ -70,7 +69,7 @@ return [
],
],
],
'saisie-dotation' => [
'saisie-dotation' => [
'type' => 'Segment',
'may_terminate' => true,
'options' => [
......@@ -87,39 +86,39 @@ return [
],
],
],
'type-dotation' => [
'type' => 'Segment',
'options' => [
'route' => '/type-dotation',
'type-dotation' => [
'type' => 'Segment',
'options' => [
'route' => '/type-dotation',
'constraints' => [
],
'defaults' => [
'defaults' => [
'action' => 'type-dotation',
],
],
'may_terminate' => true,
],
'type-dotation-saisie' => [
'type' => 'Segment',
'options' => [
'route' => '/type-dotation-saisie[/:typeDotation]',
'type-dotation-saisie' => [
'type' => 'Segment',
'options' => [
'route' => '/type-dotation-saisie[/:typeDotation]',
'constraints' => [
'typeDotation' => '[0-9]*',
],
'defaults' => [
'defaults' => [
'action' => 'type-dotation-saisie',
],
],
'may_terminate' => true,
],
'type-dotation-delete' => [
'type' => 'Segment',
'options' => [
'route' => '/type-dotation-delete/:typeDotation',
'type-dotation-delete' => [
'type' => 'Segment',
'options' => [
'route' => '/type-dotation-delete/:typeDotation',
'constraints' => [
'typeDotation' => '[0-9]*',
],
'defaults' => [
'defaults' => [
'action' => 'type-dotation-delete',
],
],
......@@ -143,31 +142,31 @@ return [
'resource' => PrivilegeController::getResourceId('Application\Controller\Budget', 'index'),
'order' => 30,
'border-color' => '#EB4995',
'pages' => [
'tableau-de-bord' => [
'pages' => [
'tableau-de-bord' => [
'label' => 'Tableau de bord',
'title' => 'Tableau de bord',
'route' => 'budget/tableau-de-bord',
'resource' => PrivilegeController::getResourceId('Application\Controller\Budget', 'tableau-de-bord'),
],
'engagements-liquidation' => [
'engagements-liquidation' => [
'label' => 'Engagements & liquidation',
'title' => 'Engagements & liquidation',
'route' => 'budget/engagements-liquidation',
'resource' => PrivilegeController::getResourceId('Application\Controller\Budget', 'engagements-liquidation'),
],
'export' => [
'export' => [
'label' => 'Export des données de paiement (CSV)',
'title' => 'Export des données de paiement (CSV)',
'route' => 'budget/export',
'resource' => PrivilegeController::getResourceId('Application\Controller\Budget', 'export'),
],
'type-dotation' => [
'label' => 'Types de dotation',
'title' => 'Types de dotations',
'route' => 'budget/type-dotation',
'type-dotation' => [
'label' => 'Types de dotation',
'title' => 'Types de dotations',
'route' => 'budget/type-dotation',
'withtarget' => true,
'resource' => PrivilegeController::getResourceId('Application\Controller\Budget', 'type-dotation'),
'resource' => PrivilegeController::getResourceId('Application\Controller\Budget', 'type-dotation'),
],
],
],
......@@ -193,7 +192,7 @@ return [
'privileges' => [
Privileges::BUDGET_VISUALISATION,
],
'assertion' => 'assertionBudget',
'assertion' => Assertion\BudgetAssertion::class,
],
[
'controller' => 'Application\Controller\Budget',
......@@ -214,7 +213,7 @@ return [
'action' => ['get-json'],
'privileges' => [
Privileges::BUDGET_VISUALISATION,
Privileges::MISE_EN_PAIEMENT_DEMANDE
Privileges::MISE_EN_PAIEMENT_DEMANDE,
],
],
[
......@@ -227,12 +226,12 @@ return [
],
[
'controller' => 'Application\Controller\Budget',
'action' => ['type-dotation'],
'action' => ['type-dotation'],
'privileges' => [Privileges::BUDGET_TYPE_DOTATION_VISUALISATION],
],
[
'controller' => 'Application\Controller\Budget',
'action' => ['type-dotation-saisie','type-dotation-delete'],
'action' => ['type-dotation-saisie', 'type-dotation-delete'],
'privileges' => [Privileges::BUDGET_TYPE_DOTATION_EDITION],
],
],
......@@ -251,7 +250,7 @@ return [
Privileges::BUDGET_EDITION_ENGAGEMENT_ETABLISSEMENT,
],
'resources' => ['Dotation', 'Structure', 'TypeRessource'],
'assertion' => 'assertionBudget',
'assertion' => Assertion\BudgetAssertion::class,
],
],
],
......@@ -259,16 +258,16 @@ return [
],
'form_elements' => [
'invokables' => [
'BudgetDotationSaisie' => Form\Budget\DotationSaisieForm::class,
'typeDotationSaisie' => Form\Budget\TypeDotationSaisieForm::class,
Form\Budget\DotationSaisieForm::class => Form\Budget\DotationSaisieForm::class,
Form\Budget\TypeDotationSaisieForm::class => Form\Budget\TypeDotationSaisieForm::class,
],
],
'service_manager' => [
'invokables' => [
'applicationTypeRessource' => Service\TypeRessourceService::class,
'applicationDotation' => Service\DotationService::class,
'assertionBudget' => Assertion\BudgetAssertion::class,
'ApplicationTypeDotation' => Service\TypeDotationService::class,
Service\TypeRessourceService::class => Service\TypeRessourceService::class,
Service\DotationService::class => Service\DotationService::class,
Assertion\BudgetAssertion::class => Assertion\BudgetAssertion::class,
Service\TypeDotationService::class => Service\TypeDotationService::class,
],
],
'controllers' => [
......
......@@ -15,8 +15,7 @@ return [
'options' => [
'route' => '/chargens',
'defaults' => [
'__NAMESPACE__' => 'Application\Controller',
'controller' => 'Chargens',
'controller' => 'Application\Controller\Chargens',
'action' => 'INDEX',
],
],
......@@ -195,35 +194,35 @@ return [
'resource' => PrivilegeController::getResourceId('Application\Controller\Chargens', 'index'),
'order' => 5,
'pages' => [
'scenario' => [
'scenario' => [
'label' => "Gestion des scénarios",
'description' => "Permet de créer, dupliquer ou supprimer des scénarios",
'route' => 'chargens/scenario',
'resource' => PrivilegeController::getResourceId('Application\Controller\Chargens', 'scenario'),
'visible' => false,
],
'seuil' => [
'seuil' => [
'label' => "Gestion des seuils de dédoublement",
'description' => "Permet de spécifier des seuils de dédoublement qui s'appliqueront à toutes les formations concernées",
'route' => 'chargens/seuil',
'resource' => PrivilegeController::getResourceId('Application\Controller\Chargens', 'seuil'),
'visible' => false,
],
'formation' => [
'formation' => [
'label' => "Paramétrage des formations",
'description' => "Permet de configurer de manière fine les formations (définition des taux d'assiduite, seuils, effectifs...)",
'route' => 'chargens/formation',
'resource' => PrivilegeController::getResourceId('Application\Controller\Chargens', 'formation'),
'visible' => false,
],
'export' => [
'export' => [
'label' => "Export des charges d'enseignement (CSV)",
'description' => "Produit un fichier qui comporte l'ensemble des données concernant les charges d'enseignement",
'route' => 'chargens/export',
'resource' => PrivilegeController::getResourceId('Application\Controller\Chargens', 'export'),
'visible' => false,
],
'depassement' => [
'depassement' => [
'label' => "Rapprochement des charges et des services d'enseignement (CSV)",
'description' => "Produit un fichier qui rapproche les services d'enseignement saisis et les charges d'enseignement calculées",
'route' => 'chargens/depassement',
......@@ -263,7 +262,7 @@ return [
Privileges::CHARGENS_SCENARIO_COMPOSANTE_EDITION,
Privileges::CHARGENS_SCENARIO_ETABLISSEMENT_EDITION,
],
'assertion' => 'assertionChargens',
'assertion' => Assertion\ChargensAssertion::class,
],
[
'controller' => 'Application\Controller\Chargens',
......@@ -332,7 +331,7 @@ return [
[
'privileges' => ChargensAssertion::SCENARIO_EDITION,
'resources' => ['Scenario', 'Structure'],
'assertion' => 'AssertionChargens',
'assertion' => Assertion\ChargensAssertion::class,
],
[
'privileges' => [
......@@ -340,7 +339,7 @@ return [
Privileges::CHARGENS_SEUIL_COMPOSANTE_EDITION,
],
'resources' => ['Structure'],
'assertion' => 'AssertionChargens',
'assertion' => Assertion\ChargensAssertion::class,
],
],
],
......@@ -356,12 +355,12 @@ return [
'service_manager' => [
'invokables' => [
'applicationScenario' => Service\ScenarioService::class,
'assertionChargens' => Assertion\ChargensAssertion::class,
Service\ScenarioService::class => Service\ScenarioService::class,
Assertion\ChargensAssertion::class => Assertion\ChargensAssertion::class,
],
'factories' => [
'applicationSeuilCharge' => Service\Factory\SeuilChargeServiceFactory::class,
'chargens' => Provider\Chargens\ChargensProviderFactory::class,
Service\Factory\SeuilChargeServiceFactory::class => Service\Factory\SeuilChargeServiceFactory::class,
Provider\Chargens\ChargensProvider::class => Provider\Chargens\ChargensProviderFactory::class,
],
],
'view_helpers' => [
......@@ -371,10 +370,10 @@ return [
],
'form_elements' => [
'invokables' => [
'chargensFiltre' => Form\Chargens\FiltreForm::class,
'chargensScenarioFiltre' => Form\Chargens\ScenarioFiltreForm::class,
'chargensDuplicationScenario' => Form\Chargens\DuplicationScenarioForm::class,
'chargensScenario' => Form\Chargens\ScenarioForm::class,
Form\Chargens\FiltreForm::class => Form\Chargens\FiltreForm::class,
Form\Chargens\ScenarioFiltreForm::class => Form\Chargens\ScenarioFiltreForm::class,
Form\Chargens\DuplicationScenarioForm::class => Form\Chargens\DuplicationScenarioForm::class,
Form\Chargens\ScenarioForm::class => Form\Chargens\ScenarioForm::class,
],
],
];
\ No newline at end of file
......@@ -15,8 +15,7 @@ return [
'options' => [
'route' => '/contrat',
'defaults' => [
'__NAMESPACE__' => 'Application\Controller',
'controller' => 'Contrat',
'controller' => 'Application\Controller\Contrat',
'action' => 'index',
],
],
......@@ -155,7 +154,7 @@ return [
'controller' => 'Application\Controller\Contrat',
'action' => ['index'],
'privileges' => Privileges::CONTRAT_VISUALISATION,