Files
@ 9a2affee4a45
Branch filter:
Location: kallithea/pylons_app/templates/admin.html - annotation
9a2affee4a45
2.1 KiB
text/html
Updated defaults bug of htmlfill + changed routing
2e1247e62c5b d924b931b488 a886f5eba757 a886f5eba757 a886f5eba757 a886f5eba757 a886f5eba757 a886f5eba757 a886f5eba757 a886f5eba757 a886f5eba757 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 f6ac79182600 d924b931b488 d924b931b488 f6ac79182600 d924b931b488 d924b931b488 d924b931b488 d924b931b488 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 4df4c0eac619 2e1247e62c5b d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 a886f5eba757 d924b931b488 d924b931b488 d924b931b488 a886f5eba757 a886f5eba757 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 d924b931b488 | ## -*- coding: utf-8 -*-
<%inherit file="base/base.html"/>
<%def name="get_form_error(element)">
%if type(c.form_errors) == dict:
%if c.form_errors.get(element,False):
<span class="error-message">
${c.form_errors.get(element,'')}
</span>
%endif
%endif
</%def>
<%def name="title()">
${_('Repository managment')}
</%def>
<%def name="breadcrumbs()">
${h.link_to(u'Home',h.url('/'))}
/
${h.link_to(u'Admin',h.url('admin_home'))}
</%def>
<%def name="page_nav()">
<li>${h.link_to(u'Home',h.url('/'))}</li>
<li class="current">${_('Admin')}</li>
</%def>
<%def name="main()">
%if c.admin_user:
<ul class="submenu">
<li>
${h.link_to(u'Repos',h.url('repos'))}
</li>
<li>
${h.link_to(u'Users',h.url('users'))}
</li>
</ul>
<br/>
<div>
<h2>Welcome ${c.admin_username}</h2>
<div>Last 5 user actions</div>
%if c.users_log:
<table>
<tr>
<td>${_('Username')}</td>
<td>${_('Repository')}</td>
<td>${_('Action')}</td>
<td>${_('Date')}</td>
</tr>
%for cnt,l in enumerate(c.users_log):
<tr class="parity${cnt%2}">
<td>${l.user.username}</td>
<td>${l.repository}</td>
<td>${l.action}</td>
<td>${l.action_date}</td>
</tr>
%endfor
</table>
%else:
${_('No actions yet')}
%endif
</div>
%else:
<div>
<br />
<h2>${_('Login')}</h2>
${h.form(h.url.current())}
<table>
<tr>
<td>${_('Username')}</td>
<td>${h.text('username')}</td>
<td>${get_form_error('username')} </td>
</tr>
<tr>
<td>${_('Password')}</td>
<td>${h.password('password')}</td>
<td>${get_form_error('password')}</td>
</tr>
<tr>
<td></td>
<td>${h.submit('login','login')}</td>
</tr>
</table>
${h.end_form()}
</div>
%endif
</%def>
|