protected function createControls()
 {
     $medien = $this->controller->kollektion->getMedien();
     $lView = new ListViewControl($this, 'lView');
     $lView->setSkin('
         <table class="table table-striped table-hover">
             <thead>
                 <tr>
                     <th>Dokument</th>
                     <th>Datum</th>
                     <th>Größe</th>
                 </tr>
             </thead>
             <tbody>
                 {controls}
             </tbody>
         </table>
     ');
     $lView->setItemSkin('
                 <tr>
                     <td><a href="' . Configuration::get('site.internalUrl') . '/medien/{me_kollektion}/{me_dateiname}">{me_titel}</a></td>
                     <td>{me_upload_am}</td>
                     <td><?php echo ceil({me_groesse} / 1024); ?> KB</td>
                 </tr>
     ');
     $lView->addItems($medien);
 }
Пример #2
0
 protected function createControls()
 {
     $panel = new CaptionedPanelControl($this, 'panel');
     $panel->setCaption('Suchergebnis');
     $item = '<p>{text}</p><a href="{site.scriptUrl}/{link}" class="button"><span>Mehr</span></a><p>&nbsp;</p>';
     $items = new ListViewControl($this, 'items');
     $items->setSkin('{controls}');
     $items->setItemSkin($item);
     $items->addItems($this->controller->hits);
     $this->controls->setVar('count', count($this->controller->hits));
 }
 protected function createControls()
 {
     $panel = new CaptionedPanelControl($this, 'pnlSmallBlog');
     $panel->setCaption('Übersicht');
     $panel->addCssClass('posts');
     $itemSkin = '
                     <dl class="dl-horizontal">
                         <dt><a href="#"><img src="{ca_hauptbild}" alt="" /></a></dt>
                         <dd>
                             <p><a href="/nfs/index.php/Aktuelles#{ca_id}"><i class="icon-calendar"></i> {ca_geschrieben_am} - {titel}</a></p>
                         </dd>
                     </dl>
                     ';
     $lView = new ListViewControl($panel, 'lViewAktuelles');
     $lView->setSkin('{controls}')->setItemSkin($itemSkin)->addItems($this->controller->kategorie->getArtikel());
 }
 /**
  * @return ListViewControl
  * @throws \Exception
  */
 private function showTabInfo()
 {
     $table = new ListViewControl(null, 'tableCache');
     $table->setSkin('<div id="cacheTarget"></div>
          <table class="table table-hover table-striped">
             <thead>
                 <tr>
                     <th>Schlüssel</th>
                     <th>Wert</th>
                     <th></th>
                 </tr>
             </thead>
             <tbody>
                 {controls}
             </tbody>
         </table>');
     $table->setItemSkin('<tr>
             <td>{key}</td>
             <td>{value}</td>
             <td>
                 <a class="btn btn-xs btn-danger nfs-ajax" data-target="cacheTarget" href="{site.scriptUrl}/Debug/removeFromCache/key/{url_key}">Löschen</a>
             </td>
         </tr>');
     $table->addItems(Cache::dump());
     return $table;
 }