<?php
/**
 * @copyright (c) Kufer Software GmbH, Loisachstrasse 4, D-84453 Mühldorf
 */

class DataMenuDetailsSelf extends DataMenuSelf
{
  
  public function __construct($urlparam)
  {
    parent::__construct($urlparam);
  }

  
  public function _getClickPath($pName = '', $pZwischenschritt = '')
  {
    
    DataMenuMain::_getClickPath();

    
    if ($this->toolsettings->titleKursBereich != '') {
      $this->clickpfad = "<span class='clickadresse'>" . ' ' . CleanOperations::cleanStringForHtml(stripslashes($this->toolsettings->titleKursBereich)) . ' ' . '</span>';
      $this->clickpfad .= "<span class='trennzeichen'>" . ' ' . CleanOperations::cleanStringContainingHtml($this->toolsettings->trennzeichenKategorie) . ' ' . '</span>';
    }
    $this->clickpfad .= $pZwischenschritt;
    $this->clickpfad .= "<span class='clickadrbold'> " . CleanOperations::cleanStringForHtml($pName) . '</span>';
    
    return $this->clickpfad;
  }

  
  public function mainmenu()
  {
    $this->getsight();
    $this->getdataarrayheader();
    $this->getdataarraybody();
    $this->getdataarrayfooter();
    $this->getdataarraynodata();
    $this->getdataarraynocolumn();
    if ($this->toolsettings->showClickpfad) {
      echo $this->getClickPath();
    }
    if (count($this->dataarraybody) == 0
        || ((count($this->dataarraybody) == 1) && ($this->dataarraybody[0]->isEmpty()))) {
      $this->shownodata();
    } else {
      $this->showheader();
      $this->showbody();
      $this->showfooter();
    }
  }

  
  public function showheader()
  {
    if(!REMOVE_DIV_HAUPTSEITE_OHNE_STATUS) {
      echo "<div class='hauptseite_ohnestatus'>\n";
    }
    echo $this->getContentAnker();
    DataMenu::showheader();
  }

  
  public function showfooter()
  {
    DataMenu::showfooter();
    if(!REMOVE_DIV_HAUPTSEITE_OHNE_STATUS) {
      echo "</div>\n\n";
    }
  }

  
  public function statusmenu($pPHP53DummyParam = '')
  {
  }

  public function shownodata()
  {
    if(!REMOVE_DIV_HAUPTSEITE_OHNE_STATUS) {
      echo "<div class='hauptseite_ohnestatus'>\n";
      DataMenu::shownodata();
      echo "</div>\n\n";
    } else {
      DataMenu::shownodata();
    }
  }
}