PHP_SMART_HOME_V3/app/views/templates/part/menu.phtml

48 lines
1.2 KiB
PHTML
Raw Normal View History

2020-05-16 15:18:27 +00:00
<div class="nav">
<?php
$menuItems = [
2020-08-31 19:23:23 +00:00
'fa-podcast' => [
'slug' => 'device',
'lngKey' => 'devices',
'path' => 'device',
],
2020-10-25 23:01:30 +00:00
'fas fa-plug' => [
'slug' => 'plugins',
'lngKey' => 'plugins',
'path' => 'plugins',
],
2020-05-16 15:18:27 +00:00
'fa-wrench' => [
'slug' => 'setting',
'lngKey' => 'settings',
'path' => 'setting',
],
'fa-calendar-o' => [
'slug' => 'automation',
'lngKey' => 'automatization',
'path' => 'automation',
],
'fa-bug' =>[
'slug' => 'log',
'lngKey' => 'log',
2020-07-23 13:16:44 +00:00
'path' => 'log',
2020-05-16 15:18:27 +00:00
],
2020-07-23 15:58:46 +00:00
'fa-server' =>[
'slug' => 'server',
'lngKey' => 'server',
'path' => 'server',
],
2020-05-16 15:18:27 +00:00
];
foreach ( $menuItems as $key => $value) {
?>
<div class="nav-item <?php echo ($ITEM == $value ? 'is-active' : ''); ?>">
<a href="<?php echo $value['path']?>">
<i class="fa <?php echo $key ?>"></i>
<span>
<?php $LANGMNG->echo('m_'.$value['lngKey']); ?>
</span>
</a>
</div>
<?php }?>
</div>