Loading config/autoload/bdd.global.php +1 −0 Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ return [ 'MV_EXT_DOTATION_LIQUIDATION', 'MV_EXT_ETAT_PAIEMENT', 'MV_LIEN', 'MV_MODULATEUR', ]], 'package' => ['excludes' => ['UCBN_LDAP', 'UNICAEN_IMPORT_AUTOGEN_PROCS__', 'OSE_ACTUL']], ], Loading data/ddl/materialized-view/MV_MODULATEUR.sql 0 → 100644 +11 −0 Original line number Diff line number Diff line SELECT ep.id element_pedagogique_id, MAX(m.ponderation_service_du) ponderation_service_du, MAX(m.ponderation_service_compl) ponderation_service_compl FROM element_pedagogique ep JOIN element_modulateur em ON em.element_id = ep.id AND em.histo_destruction IS NULL JOIN modulateur m ON m.id = em.modulateur_id GROUP BY ep.id No newline at end of file module/OffreFormation/src/Controller/ElementPedagogiqueController.php +7 −0 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ use OffreFormation\Service\Traits\ElementModulateurServiceAwareTrait; use OffreFormation\Service\Traits\ElementPedagogiqueServiceAwareTrait; use OffreFormation\Service\Traits\VolumeHoraireEnsServiceAwareTrait; use Paiement\Service\TauxRemuServiceAwareTrait; use Unicaen\BddAdmin\BddAwareTrait; use UnicaenImport\Service\Traits\SchemaServiceAwareTrait; /** Loading @@ -37,6 +38,7 @@ class ElementPedagogiqueController extends AbstractController use StructureServiceAwareTrait; use SchemaServiceAwareTrait; use TauxRemuServiceAwareTrait; use BddAwareTrait; public function voirAction() { Loading Loading @@ -97,6 +99,8 @@ class ElementPedagogiqueController extends AbstractController $this->getServiceElementPedagogique()->delete($element); }); $this->getBdd()->materializedView()->refresh('MV_MODULATEUR'); return compact('element', 'title', 'form'); } Loading Loading @@ -316,6 +320,9 @@ class ElementPedagogiqueController extends AbstractController $element = $this->getServiceElementModulateur()->addElementModulateur($element, $datasPost[$name]); } } $this->getBdd()->materializedView()->refresh('MV_MODULATEUR'); //Centres de coûts $centreCouts = [ 'fi' => $datasPost['fi'], Loading module/OffreFormation/src/Controller/Factory/ElementPedagogiqueControllerFactory.php +2 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ namespace OffreFormation\Controller\Factory; use OffreFormation\Controller\ElementPedagogiqueController; use Psr\Container\ContainerInterface; use Unicaen\BddAdmin\Bdd; use UnicaenImport\Service\SchemaService; Loading @@ -20,6 +21,7 @@ class ElementPedagogiqueControllerFactory $renderer = $container->get('ViewRenderer'); $controller = new ElementPedagogiqueController($renderer); $controller->setServiceSchema($container->get(SchemaService::class)); $controller->setBdd($container->get(Bdd::class)); return $controller; } Loading module/OffreFormation/src/Controller/Factory/ModulateurControllerFactory.php +2 −1 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ namespace OffreFormation\Controller\Factory; use Psr\Container\ContainerInterface; use OffreFormation\Controller\ModulateurController; use Unicaen\BddAdmin\Bdd; /** Loading @@ -25,7 +26,7 @@ class ModulateurControllerFactory { $controller = new ModulateurController; /* Injectez vos dépendances ICI */ $controller->setBdd($container->get(Bdd::class)); return $controller; } Loading Loading
config/autoload/bdd.global.php +1 −0 Original line number Diff line number Diff line Loading @@ -33,6 +33,7 @@ return [ 'MV_EXT_DOTATION_LIQUIDATION', 'MV_EXT_ETAT_PAIEMENT', 'MV_LIEN', 'MV_MODULATEUR', ]], 'package' => ['excludes' => ['UCBN_LDAP', 'UNICAEN_IMPORT_AUTOGEN_PROCS__', 'OSE_ACTUL']], ], Loading
data/ddl/materialized-view/MV_MODULATEUR.sql 0 → 100644 +11 −0 Original line number Diff line number Diff line SELECT ep.id element_pedagogique_id, MAX(m.ponderation_service_du) ponderation_service_du, MAX(m.ponderation_service_compl) ponderation_service_compl FROM element_pedagogique ep JOIN element_modulateur em ON em.element_id = ep.id AND em.histo_destruction IS NULL JOIN modulateur m ON m.id = em.modulateur_id GROUP BY ep.id No newline at end of file
module/OffreFormation/src/Controller/ElementPedagogiqueController.php +7 −0 Original line number Diff line number Diff line Loading @@ -17,6 +17,7 @@ use OffreFormation\Service\Traits\ElementModulateurServiceAwareTrait; use OffreFormation\Service\Traits\ElementPedagogiqueServiceAwareTrait; use OffreFormation\Service\Traits\VolumeHoraireEnsServiceAwareTrait; use Paiement\Service\TauxRemuServiceAwareTrait; use Unicaen\BddAdmin\BddAwareTrait; use UnicaenImport\Service\Traits\SchemaServiceAwareTrait; /** Loading @@ -37,6 +38,7 @@ class ElementPedagogiqueController extends AbstractController use StructureServiceAwareTrait; use SchemaServiceAwareTrait; use TauxRemuServiceAwareTrait; use BddAwareTrait; public function voirAction() { Loading Loading @@ -97,6 +99,8 @@ class ElementPedagogiqueController extends AbstractController $this->getServiceElementPedagogique()->delete($element); }); $this->getBdd()->materializedView()->refresh('MV_MODULATEUR'); return compact('element', 'title', 'form'); } Loading Loading @@ -316,6 +320,9 @@ class ElementPedagogiqueController extends AbstractController $element = $this->getServiceElementModulateur()->addElementModulateur($element, $datasPost[$name]); } } $this->getBdd()->materializedView()->refresh('MV_MODULATEUR'); //Centres de coûts $centreCouts = [ 'fi' => $datasPost['fi'], Loading
module/OffreFormation/src/Controller/Factory/ElementPedagogiqueControllerFactory.php +2 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ namespace OffreFormation\Controller\Factory; use OffreFormation\Controller\ElementPedagogiqueController; use Psr\Container\ContainerInterface; use Unicaen\BddAdmin\Bdd; use UnicaenImport\Service\SchemaService; Loading @@ -20,6 +21,7 @@ class ElementPedagogiqueControllerFactory $renderer = $container->get('ViewRenderer'); $controller = new ElementPedagogiqueController($renderer); $controller->setServiceSchema($container->get(SchemaService::class)); $controller->setBdd($container->get(Bdd::class)); return $controller; } Loading
module/OffreFormation/src/Controller/Factory/ModulateurControllerFactory.php +2 −1 Original line number Diff line number Diff line Loading @@ -4,6 +4,7 @@ namespace OffreFormation\Controller\Factory; use Psr\Container\ContainerInterface; use OffreFormation\Controller\ModulateurController; use Unicaen\BddAdmin\Bdd; /** Loading @@ -25,7 +26,7 @@ class ModulateurControllerFactory { $controller = new ModulateurController; /* Injectez vos dépendances ICI */ $controller->setBdd($container->get(Bdd::class)); return $controller; } Loading