forked from lix-project/hydra
topbar: Include "Create project" in menu.
For users who only have the "create-projects" role, actually display the item in the menu as the only option. Signed-off-by: aszlig <aszlig@redmoonstudios.org>
This commit is contained in:
parent
f6a83bcc5b
commit
cfd4843290
1 changed files with 5 additions and 2 deletions
|
@ -72,12 +72,14 @@
|
|||
[% END %]
|
||||
[% END %]
|
||||
|
||||
[% IF c.user_exists && c.check_user_roles('admin') %]
|
||||
[% IF c.user_exists && (c.check_user_roles('admin') ||
|
||||
c.check_user_roles('create-projects')) %]
|
||||
[% WRAPPER makeSubMenu title="Admin" %]
|
||||
[% IF c.check_user_roles('admin') %]
|
||||
[% IF c.check_user_roles('admin') || c.check_user_roles('create-projects') %]
|
||||
[% INCLUDE menuItem uri = c.uri_for(c.controller('Project').action_for('create')) title = "Create project" %]
|
||||
<li class="divider"></li>
|
||||
[% END %]
|
||||
[% IF c.check_user_roles('admin') %]
|
||||
[% INCLUDE menuItem
|
||||
uri = c.uri_for(c.controller('Admin').action_for('machines'))
|
||||
title = "Manage machines" %]
|
||||
|
@ -105,6 +107,7 @@
|
|||
class = "" %]
|
||||
[% END %]
|
||||
[% END %]
|
||||
[% END %]
|
||||
|
||||
</ul>
|
||||
|
||||
|
|
Loading…
Reference in a new issue