Ejemplo n.º 1
0
 public function procede()
 {
     $sFicheId = $this->oRequest->getParam('id', 'string');
     $sFicheType = $this->oRequest->getParam('type', 'string');
     if ($this->oRequest->existParam('comment')) {
         $oFiche->signal($this->oCurrentUser->getId(), $this->oRequest->getParam('comment', 'string'));
         Logger::log('admin', 'La fiche du film ' . $oFiche->getTitle() . ' a été signalée par ' . $this->oCurrentUser->getLogin());
         $this->oView->addAlert('La fiche a été signalée.', 'success');
     }
     //Création de la fiche
     $sClass = 'Fiche' . $sFicheType;
     $this->oFiche = new $sClass();
     $this->oFiche->loadFromId($sFicheId);
     //Création de l'entête
     $this->setHeader($sFicheType);
     //Création du menu
     $this->oView->addData('menu', array());
     //Affichage du Poster
     $this->oView->addData('poster', $this->oFiche->getPoster());
     //Affichage du bouton "Signaler"
     $this->oView->addData('signal', $this->createSignalPopup('film', $sFicheId));
     //Affichage du lien externe :
     $this->setExternalLink($sFicheType);
     //Affichage des détails
     $this->createDetails($sFicheType);
     //Affichage des releases
     $this->createReleasesTable($sFicheType);
     $this->oView->create();
 }