123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051 |
- <?php
- $listMenu = [];
- // $listMenu[] = [ 'label' => "Faktury", 'url' => "index.php?_route=ViewTableAjax&namespace=default_db/api_produkty_103075_view", 'ns' => "default_db/api_produkty_103075_view" ];
- $activeViewTableNS = ('ViewTableAjax' === V::get('_route', '', $_GET)) ? V::get('namespace', '', $_GET) : '';
- $changePassLink = 'index.php?_route=UrlAction_RemindPasswd';
- // $changePassLink = 'index.php?_route=UrlAction_ChangePassword'; // TODO
- ?>
- <nav class="navbar navbar-inverse" style="border-radius:0">
- <div class="container-fluid">
- <div class="navbar-header">
- <a href="index.php" class="navbar-brand" style="padding:2px">
- <img src="<?= $this->asset("assets/logo-biall-net.png"); ?>" alt="BIALL-NET" style="height:46px"/>
- </a>
- </div>
- <div class="collapse navbar-collapse">
- <?= UI::h('ul', [ 'class' => "nav navbar-nav" ], array_map(function ($itemMenu) use ($activeViewTableNS) {
- $ns = $itemMenu['ns'];
- return UI::h('li', array_merge(
- [],
- (!empty($activeViewTableNS) && $ns === $activeViewTableNS) ? [ 'class' => "active" ] : []
- ), [
- UI::h('a', [ 'href' => $itemMenu['url'] ], $itemMenu['label']),
- ]);
- }, $listMenu)); ?>
- <div class="navbar-form navbar-right">
- <div class="btn-group">
- <button type="button" class="btn btn-link" style="margin:0; padding:6px 8px 4px 8px;"><?php S::show_session_timer(); ?></button>
- <div class="btn-group">
- <button id="ProcesMenuLoginDropdownLink" type="button" class="btn btn-link dropdown-toggle" data-toggle="dropdown" aria-expanded="false"><?= User::getName(); ?> <span class="caret"></span></button>
- <ul class="dropdown-menu" role="menu">
- <li><a href="<?= $changePassLink; ?>"><i class="glyphicon glyphicon-lock"></i> Zmień hasło</a></li>
- <li class="divider"></li>
- <li><a href="index.php?LOGIN=LOGOUT"><i class="glyphicon glyphicon-off"></i> Wyloguj</a></li>
- </ul>
- </div>
- <div class="btn-group">
- <a class="btn btn-link" href="index.php?LOGIN=LOGOUT"><i class="glyphicon glyphicon-off"></i> Wyloguj</a>
- </div>
- </div>
- </div>
- </div>
- </div>
- </nav>
|