openrat-cms

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs

commit 34ecbe2411467a316f8f5ab8f8f11ec373d83ca9
parent 9dabe2e43f5fb31b95397495595404a47798a6fe
Author: Jan Dankert <devnull@localhost>
Date:   Tue, 12 Dec 2017 22:27:09 +0100

Header-Links brauchen wir auch weiterhin.

Diffstat:
action/FolderAction.class.php | 6+++---
modules/template-engine/components/html/header/Header.class.php | 36+++++++++++++++++++-----------------
2 files changed, 22 insertions(+), 20 deletions(-)

diff --git a/action/FolderAction.class.php b/action/FolderAction.class.php @@ -1303,9 +1303,9 @@ class FolderAction extends ObjectAction if ( $o->hasRight(ACL_READ) ) { $list[$id]['id' ] = $id; - $list[$id]['name'] = Text::maxLength( 30,$o->name ); - $list[$id]['filename'] = Text::maxLength( 20,$o->filename ); - $list[$id]['desc'] = Text::maxLength( 30,$o->desc ); + $list[$id]['name'] = Text::maxLength( $o->name ,30); + $list[$id]['filename'] = Text::maxLength( $o->filename ,20); + $list[$id]['desc'] = Text::maxLength( $o->desc ,30); if ( $list[$id]['desc'] == '' ) $list[$id]['desc'] = lang('NO_DESCRIPTION_AVAILABLE'); $list[$id]['desc'] = 'ID '.$id.' - '.$list[$id]['desc']; diff --git a/modules/template-engine/components/html/header/Header.class.php b/modules/template-engine/components/html/header/Header.class.php @@ -4,23 +4,25 @@ namespace template_engine\components; class HeaderComponent extends Component { - public function begin() - { - /* -<?php if(!empty($attr_views)) { ?> - <div class="headermenu"> - <?php foreach( explode(',',$attr_views) as $attr_tmp_view ) { ?> - <div class="toolbar-icon clickable"> - <a href="javascript:void(0);" data-type="dialog" data-name="<?php echo lang('MENU_'.$attr_tmp_view) ?>" data-method="<?php echo $attr_tmp_view ?>"> - <img src="<?php echo $image_dir ?>icon/<?php echo $attr_tmp_view ?>.png" title="<?php echo lang('MENU_'.$attr_tmp_view.'_DESC') ?>" /> <?php echo lang('MENU_'.$attr_tmp_view) ?> - </a> - </div> - <?php } ?> - </div> -<?php } ?> - */ - - } + public $views; + + public function begin() + { + if (isset($this->views)) { + echo '<div class="headermenu">'; + + foreach (explode(',', $this->views) as $view) { + echo '<div class="toolbar-icon clickable">'; + echo '<a href="javascript:void(0);" data-type="dialog" data-name="<?php echo lang(\'MENU_' . strtoupper($view ). '\') ?>" data-method="' . $view . '">'; + echo '<img src="./themes/default/images/icon/action/' . $view . '.svg" title="<?php echo lang(\'MENU_' . $view . '_DESC\') ?>" /><?php echo lang(\'MENU_' . $view . '\') ?>'; + echo '</a>'; + echo '</div>'; + } + echo '</div>'; + + } + + } }