## -*- coding: utf-8 -*- <%inherit file="root.html"/>
<% messages = h.flash.pop_messages() %> % if messages: % endif
${next.main()}
### MAKO DEFS ### <%def name="breadcrumbs()"> <%def name="context_bar(current)"> ${repo_context_bar(current)} <%def name="admin_menu()"> <%def name="admin_menu_simple()"> <%def name="repo_context_bar(current=None)"> <% def follow_class(): if c.repository_following: return h.literal('following') else: return h.literal('follow') %> <% def is_current(selected): if selected == current: return h.literal('class="current"') %>
## TODO: this check feels wrong, it would be better to have a check for permissions ## also it feels like a job for the controller %if c.rhodecode_user.username != 'default': %endif
<%def name="usermenu()"> ## USER MENU
  • avatar %if c.rhodecode_user.username != 'default': ${c.rhodecode_user.username} %if c.unread_notifications != 0: ${c.unread_notifications} %endif %else: ${_('Not logged in')} %endif
    %if c.rhodecode_user.username == 'default':

    ${_('Login to your account')}

    ${h.form(h.url('login_home',came_from=h.url.current()))}
    ${h.text('username',class_='focus')}
    ${h.password('password',class_='focus')}
    ${h.link_to(_('Forgot password ?'),h.url('reset_password'))}
    %if h.HasPermissionAny('hg.admin', 'hg.register.auto_activate', 'hg.register.manual_activate')(): ${h.link_to(_("Don't have an account ?"),h.url('register'))} %endif
    ${h.submit('sign_in',_('Log In'),class_="ui-btn xsmall")}
    ${h.end_form()} %else: %endif
  • <%def name="menu(current=None)"> <% def is_current(selected): if selected == current: return h.literal('class="current"') %>