23 lines
679 B
PHP
23 lines
679 B
PHP
|
<?php
|
||
|
class Application_Controller_Plugin_Menu extends Zend_Controller_Plugin_Abstract
|
||
|
{
|
||
|
/**
|
||
|
* Créer le menu en fonction des besoins et des paramètres en entrée
|
||
|
* @param Zend_Controller_Request_Abstract $request
|
||
|
*/
|
||
|
public function postDispatch(Zend_Controller_Request_Abstract $request)
|
||
|
{
|
||
|
$layout = Zend_Layout::getMVCInstance();
|
||
|
$view = $layout->getView();
|
||
|
|
||
|
$siret = $request->getParam('siret', null);
|
||
|
$id = $request->getParam('id', null);
|
||
|
|
||
|
if ($layout->isEnabled()) {
|
||
|
require_once 'Scores/Menu.php';
|
||
|
$computeMenu = new Menu($siret, $id);
|
||
|
$menu = $computeMenu->getMenu();
|
||
|
$view->navigation($menu);
|
||
|
}
|
||
|
}
|
||
|
}
|