##// END OF EJS Templates
Edit groups is more consistent on how we edit objects in admin panels
marcink -
r3194:d7282940 beta
parent child Browse files
Show More
@@ -1,69 +1,74
1 ## -*- coding: utf-8 -*-
1 ## -*- coding: utf-8 -*-
2 <%inherit file="/base/base.html"/>
2 <%inherit file="/base/base.html"/>
3
3
4 <%def name="title()">
4 <%def name="title()">
5 ${_('Repositories groups administration')} - ${c.rhodecode_name}
5 ${_('Repositories groups administration')} - ${c.rhodecode_name}
6 </%def>
6 </%def>
7
7
8
8
9 <%def name="breadcrumbs_links()">
9 <%def name="breadcrumbs_links()">
10 ${h.link_to(_('Admin'),h.url('admin_home'))} &raquo; ${_('Repositories')}
10 ${h.link_to(_('Admin'),h.url('admin_home'))} &raquo; ${_('Repositories')}
11 </%def>
11 </%def>
12 <%def name="page_nav()">
12 <%def name="page_nav()">
13 ${self.menu('admin')}
13 ${self.menu('admin')}
14 </%def>
14 </%def>
15 <%def name="main()">
15 <%def name="main()">
16 <div class="box">
16 <div class="box">
17 <!-- box / title -->
17 <!-- box / title -->
18 <div class="title">
18 <div class="title">
19 ${self.breadcrumbs()}
19 ${self.breadcrumbs()}
20 <ul class="links">
20 <ul class="links">
21 <li>
21 <li>
22 <span>${h.link_to(_(u'ADD NEW GROUP'),h.url('new_repos_group'))}</span>
22 <span>${h.link_to(_(u'ADD NEW GROUP'),h.url('new_repos_group'))}</span>
23 </li>
23 </li>
24 </ul>
24 </ul>
25 </div>
25 </div>
26 <!-- end box / title -->
26 <!-- end box / title -->
27 <div class="table">
27 <div class="table">
28 % if c.groups:
28 % if c.groups:
29 <table class="table_disp">
29 <table class="table_disp">
30
30
31 <thead>
31 <thead>
32 <tr>
32 <tr>
33 <th class="left"><a href="#">${_('Group name')}</a></th>
33 <th class="left"><a href="#">${_('Group name')}</a></th>
34 <th class="left"><a href="#">${_('Description')}</a></th>
34 <th class="left"><a href="#">${_('Description')}</a></th>
35 <th class="left"><a href="#">${_('Number of toplevel repositories')}</a></th>
35 <th class="left"><a href="#">${_('Number of toplevel repositories')}</a></th>
36 <th class="left">${_('action')}</th>
36 <th class="left" colspan="2">${_('action')}</th>
37 </tr>
37 </tr>
38 </thead>
38 </thead>
39
39
40 ## REPO GROUPS
40 ## REPO GROUPS
41
41
42 % for gr in c.groups:
42 % for gr in c.groups:
43 <% gr_cn = gr.repositories.count() %>
43 <% gr_cn = gr.repositories.count() %>
44 <tr>
44 <tr>
45 <td>
45 <td>
46 <div style="white-space: nowrap">
46 <div style="white-space: nowrap">
47 <img class="icon" alt="${_('Repositories group')}" src="${h.url('/images/icons/database_link.png')}"/>
47 <img class="icon" alt="${_('Repositories group')}" src="${h.url('/images/icons/database_link.png')}"/>
48 ${h.link_to(h.literal(' &raquo; '.join(map(h.safe_unicode,[g.name for g in gr.parents+[gr]]))),url('edit_repos_group',id=gr.group_id))}
48 ${h.link_to(h.literal(' &raquo; '.join(map(h.safe_unicode,[g.name for g in gr.parents+[gr]]))), url('repos_group_home',group_name=gr.group_name))}
49 </div>
49 </div>
50 </td>
50 </td>
51 <td>${gr.group_description}</td>
51 <td>${gr.group_description}</td>
52 <td><b>${gr_cn}</b></td>
52 <td><b>${gr_cn}</b></td>
53 <td>
53 <td>
54 ${h.form(url('repos_group', id=gr.group_id),method='delete')}
54 <a href="${h.url('edit_repos_group',id=gr.group_id)}" title="${_('edit')}">
55 ${h.submit('remove_%s' % gr.name,_('delete'),class_="delete_icon action_button",onclick="return confirm('"+ungettext('Confirm to delete this group: %s with %s repository','Confirm to delete this group: %s with %s repositories',gr_cn) % (gr.name,gr_cn)+"');")}
55 ${h.submit('edit_%s' % gr.group_name,_('edit'),class_="edit_icon action_button")}
56 ${h.end_form()}
56 </a>
57 </td>
57 </td>
58 <td>
59 ${h.form(url('repos_group', id=gr.group_id),method='delete')}
60 ${h.submit('remove_%s' % gr.name,_('delete'),class_="delete_icon action_button",onclick="return confirm('"+ungettext('Confirm to delete this group: %s with %s repository','Confirm to delete this group: %s with %s repositories',gr_cn) % (gr.name,gr_cn)+"');")}
61 ${h.end_form()}
62 </td>
58 </tr>
63 </tr>
59 % endfor
64 % endfor
60
65
61 </table>
66 </table>
62 % else:
67 % else:
63 ${_('There are no repositories groups yet')}
68 ${_('There are no repositories groups yet')}
64 % endif
69 % endif
65
70
66 </div>
71 </div>
67 </div>
72 </div>
68
73
69 </%def>
74 </%def>
General Comments 0
You need to be logged in to leave comments. Login now