Mercurial > kallithea
comparison rhodecode/templates/admin/permissions/permissions.html @ 3623:ce9a226e0867 beta
sort permission lists by (repository) name
This also exhibits too much code in templates and code/template duplication.
author | Mads Kiilerich <madski@unity3d.com> |
---|---|
date | Thu, 28 Mar 2013 01:10:45 +0100 |
parents | 91ff741c4de5 |
children | 32cb8d45f330 |
comparison
equal
deleted
inserted
replaced
3622:91ff741c4de5 | 3623:ce9a226e0867 |
---|---|
117 <th class="left">${_('Name')}</th> | 117 <th class="left">${_('Name')}</th> |
118 <th class="left">${_('Permission')}</th> | 118 <th class="left">${_('Permission')}</th> |
119 <th class="left">${_('Edit Permission')}</th> | 119 <th class="left">${_('Edit Permission')}</th> |
120 </thead> | 120 </thead> |
121 <tbody> | 121 <tbody> |
122 %for k in c.perm_user.permissions[section]: | 122 %for k in sorted(c.perm_user.permissions[section], key=lambda s: s.lower): |
123 <% | 123 <% |
124 if section != 'global': | 124 if section != 'global': |
125 section_perm = c.perm_user.permissions[section].get(k) | 125 section_perm = c.perm_user.permissions[section].get(k) |
126 _perm = section_perm.split('.')[-1] | 126 _perm = section_perm.split('.')[-1] |
127 else: | 127 else: |