navigation.html.ep 3.36 KB
Newer Older
joansp's avatar
joansp committed
1
<!-- Navigation -->
amesones's avatar
amesones committed
2
3
4
5
6
        <nav class="navbar \
% if ($navbar_custom) {
navbar-custom \
% }
navbar-inverse navbar-fixed-top" role="navigation">
joansp's avatar
joansp committed
7
8
            <!-- Brand and toggle get grouped for better mobile display -->
            <div class="navbar-header">
9

Francesc Guasch's avatar
Francesc Guasch committed
10
                <a class="navbar-brand" href="/index.html">RAVADA VDI</a>
joansp's avatar
joansp committed
11
12
13
            </div>
            <!-- Top Menu Items -->
            <ul class="nav navbar-right top-nav">
amesones's avatar
amesones committed
14
% if ($_logged_in) {
15
% if ( !$_anonymous ) {
joansp's avatar
joansp committed
16
                <li>
17
                        <a href="/"><i class="fa fa-fw fa-desktop"></i><%=l 'Available Machines' %></a>
joansp's avatar
joansp committed
18
                </li>
19
% }
20
% if (defined $_user && $_user->is_operator ) {
joansp's avatar
joansp committed
21
                <li class="dropdown">
22
                  <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button">
23
                    <i class="fa fa-wrench"></i>&nbsp;<%=l 'Admin tools' %><span class="caret"></span></a>
24
25
                  <ul class="dropdown-menu">
                    <li><a href="/admin/machines">
Francesc Guasch's avatar
Francesc Guasch committed
26
                      <i class="fa fa-desktop" aria-hidden="true"></i>&nbsp;<%=l 'machines' %></a>
27
                    </li>
Francesc Guasch's avatar
Francesc Guasch committed
28
%                   if ($_user->is_admin || $_user->can_grant || $_user->can_manage_users) {
29
                        <li><a href="/admin/users">
Francesc Guasch's avatar
Francesc Guasch committed
30
31
32
33
                        <i class="fa fa-user" aria-hidden="true"></i>&nbsp;<%=l 'users' %></a>
                        </li>
                        <li><a href="/admin/nodes">
                        <i class="fa fa-server" aria-hidden="true"></i>&nbsp;<%=l 'nodes' %></a>
34
35
                        </li>
%                   }
36
                    <li><a href="/admin/messages">
Fernando Verdugo's avatar
Fernando Verdugo committed
37
                    <i class="fa fa-envelope" aria-hidden="true"></i>&nbsp;<%=l 'messages' %></a>
38
                    </li>
fv3rdugo's avatar
fv3rdugo committed
39
% if ($monitoring) {
fv3rdugo's avatar
fv3rdugo committed
40
                    <li><a href="/admin/monitoring">
Fernando Verdugo's avatar
Fernando Verdugo committed
41
                      <i class="fas fa-tachometer-alt" aria-hidden="true"></i>&nbsp;<%=l 'monitoring' %></a>
fv3rdugo's avatar
fv3rdugo committed
42
                    </li>
fv3rdugo's avatar
fv3rdugo committed
43
% }
44
                  </ul>
joansp's avatar
joansp committed
45
                </li>
46
% }
47
% if ( !$_anonymous ) {
fv3rdugo's avatar
fv3rdugo committed
48
                <li class="dropdown">
49
                    <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-question"></i>&nbsp;<%=l 'Help' %><span class="caret"></span></a>
fv3rdugo's avatar
fv3rdugo committed
50
                    <ul class="dropdown-menu">
fv3rdugo's avatar
fv3rdugo committed
51
                        <li><a href="/requirements"><i class="fa fa-cogs"></i>&nbsp;<%=l 'Requirements' %></a></li>
fv3rdugo's avatar
fv3rdugo committed
52
                        <li role="separator" class="divider"></li>
53
                        <li><a href="/about"><i class="fa fa-info-circle"></i>&nbsp;<%=l 'About' %></a></li>
fv3rdugo's avatar
fv3rdugo committed
54
55
                    </ul>
                </li>
56
% }
fv3rdugo's avatar
fv3rdugo committed
57

58
% if ( !$_anonymous ) {
59
                <li class="dropdown">
joansp's avatar
joansp committed
60
                    <a href="#" class="dropdown-toggle" data-toggle="dropdown" role="button" aria-haspopup="true" aria-expanded="false"><i class="fa fa-user"></i>&nbsp;<%= $_logged_in %><span class="caret"></span></a>
61
                    <ul class="dropdown-menu">
62
                        <li role="separator" class="divider"></li>
63
                        <li><a href="/user_settings"><i class="fa fa-cog" aria-hidden="true"></i><%=l 'Settings' %></a></li>
64
                        <li><a href="/logout"><i class="fa fa-fw fa-power-off"></i><%=l 'Log Out' %></a></li>
65
66
                    </ul>
                </li>
amesones's avatar
amesones committed
67
% }
68
% }
69

joansp's avatar
joansp committed
70
            </ul>
71

72

73
        </nav>