Subversion Repositories eFlore/Applications.eflore-consultation

Rev

Rev 501 | Rev 1018 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | RSS feed

<?php
// declare(encoding='UTF-8');
/**
 * Affiche un pop-up avec les infos d'une illustration.
 *
 * @category    php 5.2
 * @package             eFlore-consultation
 * @author              Delphine CAUQUIL <delphine@tela-botanica.org>
 * @author              Jean-Pascal MILCENT <jpm@tela-botanica.org>
 * @copyright   Copyright (c) 2012, Tela Botanica (accueil@tela-botanica.org)
 * @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             $Id$
 */

class PopupIllustrations extends aControleur {
        private $conteneur = null;
        private $id_image = '';
        private $images = null;
        private $appUrls = null;

        public function initialiser() {
                $this->capturerParametres();
                $this->conteneur = new Conteneur();
                $this->images = $this->conteneur->getApiImages();
                $this->appUrls = $this->conteneur->getAppUrls();
        }

        private function capturerParametres() {
                if (isset($_GET['id'])) {
                        $this->id_image = $_GET['id'];
                }
        }

        public function executerActionParDefaut() {
                $this->executerFiche();
        }

        public function executerFiche(){
                $infos = array();
                $this->images->setProjet('cel');
                $img = $this->images->getInfosImageParIdImage($this->id_image);
                Debug::printr($img);
                $infos['id'] = $this->id_image;
                $infos['image'] = $img;
                $infos['urlContact'] = $this->appUrls->obtenirUrlPopUpContact($img['auteur.id'], $this->id_image);

                $this->setSortie(self::RENDU_CORPS, $this->getVue('popup_fiche_illustrations', $infos));
        }

}
?>