Subversion Repositories Applications.referentiel

Compare Revisions

Ignore whitespace Rev 270 → Rev 271

/trunk/interfaces/controleurs/Informations.php
New file
0,0 → 1,70
<?php
// declare(encoding='UTF-8');
/**
* Classe Controleur du module Accueil.
* Affichage les infos sur l'ensemble des référentiels disponibles.
*
* @package Referentiel
* @category Php5.2
* @author Jean-Pascal MILCENT <jpm@tela-botanica.org>
* @copyright 2010 Tela-Botanica
* @license http://www.cecill.info/licences/Licence_CeCILL_V2-fr.txt Licence CECILL
* @license http://www.gnu.org/licenses/gpl.html Licence GNU-GPL
* @version SVN: $Id$
*/
class Informations extends AppliControleur {
private $referentiel = null;
private $referentielDao = null;
public function __construct() {
parent::__construct();
// Récupération de paramêtres
if (isset($_GET['ref'])) { // code du projet courrant
$this->referentiel = strtolower(strip_tags($_GET['ref']));
}
// Chargement des DAO nécessaires
$this->referentielDao = new ReferentielDao();
}
//+----------------------------------------------------------------------------------------------------------------+
// Méthodes
/**
* Fonction d'affichage par défaut
*/
public function executerActionParDefaut() {
return $this->afficherDetail();
}
 
/**
* Affiche le détail d'un référentiel et la liste des actions possibles
*/
public function afficherDetail() {
$donnees = array();
$this->definirCommeModulePrincipal('Informations');
// Traitement de l'info sur le code du référentiel
if (isset($this->referentiel)) {
$this->construireMenu($this->referentiel);
$this->construireFilAriane($this->referentiel);
$donnees['referentiel'] = $this->referentiel;
$donnees['nom_referentiel'] = $this->referentielDao->getNom($this->referentiel);
$donnees['url_menu_test'] = $this->obtenirUrlMenuTest($this->referentiel);
$donnees['url_menu_versionnage'] = $this->obtenirUrlMenuVersionnage($this->referentiel);
$donnees['url_menu_consultation'] = $this->obtenirUrlMenuConsultation($this->referentiel);
} else {
$this->addMessage("Aucun code de projet de référentiel n'est indiqué (Ex. bdtfx).");
}
$donnees['messages'] = $this->getMessages();
$this->traiterEsperluette($donnees);
$this->setSortie(self::RENDU_CORPS, $this->getVue('detail_referentiel', $donnees), false);
}
}
?>