view pylons_app/templates/users.html @ 63:3cf0603cd4f5

Templating small fixes
author Marcin Kuzminski <marcin@python-blog.com>
date Sat, 10 Apr 2010 16:43:34 +0200
parents 73f413946c14
children 3ac4350b7848
line wrap: on
line source

<%inherit file="base/base.html"/>
<%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'))}
    /
    ${h.link_to(u'Users managment',h.url('users'))}
</%def>
<%def name="page_nav()">
    <li>${h.link_to(u'Home',h.url('/'))}</li>
    <li class="current">${_('Admin')}</li>
</%def>
<%def name="main()">
    <ul class="submenu">
        <li>
            ${h.link_to(u'Repos',h.url('repos'))}
        </li>
        <li class="current_submenu">
            ${h.link_to(u'Users',h.url('users'))}
        </li>
    </ul>
	<div>
        <h2>${_('Mercurial users')}</h2>
        <table>
         <tr>
            <th>Id</th>
            <th>Username</th>
            <th>Active</th>
            <th>Admin</th>
            <th>Action</th>
         </tr>
            %for user in c.users_list:
                <tr>
                    <td>${user.user_id}</td>
                    <td>${h.link_to(user.username,h.url('edit_user', id=user.user_id))}</td>
                    <td>${user.active}</td>
                    <td>${user.admin}</td>
                    <td>
	                    ${h.form(url('user', id=user.user_id),method='delete')}
	                    	${h.submit('remove','remove',class_="submit")}
	                    ${h.end_form()}
        			</td>
                </tr>
            %endfor
        </table>
        <h3>${h.link_to(u'Add user',h.url('new_user'))}</h3>        
    </div>

</%def>