-
{% if user_details is none %}
- {{ h.link_to('Login', h.url_for(controller='/auth/login'), class='yui3-menuitem-content') }} {% else %} {# User is logged in #}
- {{ h.link_to('Home', h.url_for(controller='/u/%s' % user_details.login), class='yui3-menuitem-content') }} {% if user_details.projects|length %}
-
Projects
-
{# List of projects that this user is in #}
{% for membership in user_details.projects %}
- {{ h.link_to(membership.project.name, h.url_for(controller='/project', project_name=membership.project.name), class='yui3-menuitem-content' ) }} {% endfor %}
{% endif %} {# User Projects #}
{% if h.has_site_role(h.PROJECT_ADMIN) or h.has_site_role(h.USER_ADMIN) %}
-
Admin
-
{% if h.has_site_role(h.USER_ADMIN) %}
-
Person
- {{ h.link_to('List / Edit', h.url_for(controller='/a/person/retrieve'), class='yui3-menuitem-content') }}
- {{ h.link_to('Create New', h.url_for(controller='/a/person/create'), class='yui3-menuitem-content') }}
-
Project
- {{ h.link_to('List / Edit', h.url_for(controller='/a/project/retrieve'), class='yui3-menuitem-content') }}
- {{ h.link_to('Create New', h.url_for(controller='/a/project/create'), class='yui3-menuitem-content') }}
{% endif %} {# User site-role #}
{# Acct Settings & Logout link gets forced to the right: #}
-
Person
- {{ h.link_to('Logout', h.url_for('/auth/logout'), class='yui3-menuitem-content') }}
- {{ h.link_to('Account Settings', h.url_for(controller='/admin/person', action='update', id=user_details.id), class='yui3-menuitem-content settings', style="padding-left: 18px;") }} {% endif %}