Beispiel #1
0
 private function createView()
 {
     //Affichage des Trackers
     $this->oView->addData('titre', 'Signalements des membres');
     //Construction du tableau
     $oTable = new TableGenerator();
     $oTable->setId(md5('Signalements'));
     $oTable->addColumn('Date');
     $oTable->addColumn('Utilisateur');
     $oTable->addColumn('Fiche');
     $oTable->addColumn('Commentaire');
     $oTable->addColumn('');
     $aFiches = Fiche::getSignaledFiche();
     if ($aFiches != false) {
         foreach ($aFiches as $aFiche) {
             $oClearButton = new View('minibutton');
             $oClearButton->addData('link', 'index.php?p=modwarnings&type=' . $aFiche['type'] . '&id=' . $aFiche['id_fiche']);
             $oClearButton->addData('icon', 'fa-check');
             $oClearButton->addData('style', 'success');
             $oClearButton->create();
             $sLink = '<a href="index.php?p=fichedetail&type=' . $aFiche['type'] . '&id=' . $aFiche['id_fiche'] . '">[' . $aFiche['type'] . '] ' . $aFiche['id_fiche'] . '</a>';
             $oTable->addLine(array($aFiche['date'], $aFiche['login_user'], $sLink, $this->createCommentPopup($aFiche), $oClearButton->getCode()));
         }
     } else {
         $oTable->setBottom('Aucun signalement');
     }
     $oTable->create();
     $this->oView->addData('content', $oTable->getCode());
     $this->oView->create();
 }