easyappointments/application/views/layouts/backend/backend_header.php

91 lines
3.8 KiB
PHP
Raw Normal View History

<?php
/**
* @var array $privileges
* @var string $active_menu
*/
?>
2020-05-05 20:35:33 +03:00
<nav id="header" class="navbar navbar-expand-md navbar-dark">
<div id="header-logo" class="navbar-brand">
<img src="<?= base_url('assets/img/logo.png') ?>">
2020-10-21 21:36:05 +03:00
<h6>EASY!APPOINTMENTS</h6>
<small>Open Source Appointment Scheduler</small>
2020-05-05 20:35:33 +03:00
</div>
<button type="button" class="navbar-toggler" data-toggle="collapse" data-target="#header-menu">
2020-05-05 20:35:33 +03:00
<span class="sr-only">Toggle navigation</span>
<span class="navbar-toggler-icon"></span>
</button>
2020-05-05 20:35:33 +03:00
<div id="header-menu" class="collapse navbar-collapse flex-row-reverse">
<ul class="navbar-nav">
2020-06-18 21:37:11 +03:00
<?php $hidden = ($privileges[PRIV_APPOINTMENTS]['view'] == TRUE) ? '' : 'd-none' ?>
2020-05-05 20:35:33 +03:00
<?php $active = ($active_menu == PRIV_APPOINTMENTS) ? 'active' : '' ?>
<li class="nav-item <?= $active . $hidden ?>">
<a href="<?= site_url('backend') ?>" class="nav-link"
2020-12-09 15:17:45 +03:00
data-tippy-content="<?= lang('manage_appointment_record_hint') ?>">
<i class="fas fa-calendar-alt mr-2"></i>
2020-05-05 20:35:33 +03:00
<?= lang('calendar') ?>
</a>
</li>
2020-06-18 21:37:11 +03:00
<?php $hidden = ($privileges[PRIV_CUSTOMERS]['view'] == TRUE) ? '' : 'd-none' ?>
2020-05-05 20:35:33 +03:00
<?php $active = ($active_menu == PRIV_CUSTOMERS) ? 'active' : '' ?>
<li class="nav-item <?= $active . $hidden ?>">
<a href="<?= site_url('backend/customers') ?>" class="nav-link"
2020-12-09 15:17:45 +03:00
data-tippy-content="<?= lang('manage_customers_hint') ?>">
<i class="fas fa-user-friends mr-2"></i>
2020-05-05 20:35:33 +03:00
<?= lang('customers') ?>
</a>
</li>
2020-06-18 21:37:11 +03:00
<?php $hidden = ($privileges[PRIV_SERVICES]['view'] == TRUE) ? '' : 'd-none' ?>
2020-05-05 20:35:33 +03:00
<?php $active = ($active_menu == PRIV_SERVICES) ? 'active' : '' ?>
<li class="nav-item <?= $active . $hidden ?>">
<a href="<?= site_url('backend/services') ?>" class="nav-link"
2020-12-09 15:17:45 +03:00
data-tippy-content="<?= lang('manage_services_hint') ?>">
<i class="fas fa-business-time mr-2"></i>
2020-05-05 20:35:33 +03:00
<?= lang('services') ?>
</a>
</li>
2020-12-09 15:17:45 +03:00
<?php $hidden = ($privileges[PRIV_USERS]['view'] == TRUE) ? '' : 'd-none' ?>
2020-05-05 20:35:33 +03:00
<?php $active = ($active_menu == PRIV_USERS) ? 'active' : '' ?>
<li class="nav-item <?= $active . $hidden ?>">
<a href="<?= site_url('backend/users') ?>" class="nav-link"
2020-12-09 15:17:45 +03:00
data-tippy-content="<?= lang('manage_users_hint') ?>">
<i class="fas fa-users-cog mr-2"></i>
2020-05-05 20:35:33 +03:00
<?= lang('users') ?>
</a>
</li>
2020-05-05 20:35:33 +03:00
<?php $hidden = ($privileges[PRIV_SYSTEM_SETTINGS]['view'] == TRUE
2020-12-09 15:17:45 +03:00
|| $privileges[PRIV_USER_SETTINGS]['view'] == TRUE) ? '' : 'd-none' ?>
2020-05-05 20:35:33 +03:00
<?php $active = ($active_menu == PRIV_SYSTEM_SETTINGS) ? 'active' : '' ?>
<li class="nav-item <?= $active . $hidden ?>">
<a href="<?= site_url('backend/settings') ?>" class="nav-link"
2020-12-09 15:17:45 +03:00
data-tippy-content="<?= lang('settings_hint') ?>">
<i class="fas fa-cogs mr-2"></i>
2020-05-05 20:35:33 +03:00
<?= lang('settings') ?>
</a>
</li>
2020-05-05 20:35:33 +03:00
<li class="nav-item">
<a href="<?= site_url('user/logout') ?>" class="nav-link"
2020-12-09 15:17:45 +03:00
data-tippy-content="<?= lang('log_out_hint') ?>">
<i class="fas fa-sign-out-alt mr-2"></i>
2020-05-05 20:35:33 +03:00
<?= lang('log_out') ?>
</a>
</li>
</ul>
</div>
</nav>
<div id="notification" style="display: none;"></div>
<div id="loading" style="display: none;">
2017-11-16 01:35:11 +03:00
<div class="any-element animation is-loading">
2017-11-16 01:20:04 +03:00
&nbsp;
</div>
</div>