mirror of
https://salsa.debian.org/freeipa-team/freeipa.git
synced 2024-12-28 01:41:14 -06:00
Sort users by last name. Make labeleduri a link.
This commit is contained in:
parent
0b2b499e42
commit
f8a9d2021a
@ -32,19 +32,19 @@ class IPAController(controllers.Controller):
|
||||
def sort_group_member(self, a, b):
|
||||
"""Comparator function used for sorting group members."""
|
||||
if a.getValue('uid') and b.getValue('uid'):
|
||||
if a.getValue('givenname') == b.getValue('givenname'):
|
||||
if a.getValue('sn') == b.getValue('sn'):
|
||||
if a.getValue('sn') == b.getValue('sn'):
|
||||
if a.getValue('givenName') == b.getValue('givenName'):
|
||||
if a.getValue('uid') == b.getValue('uid'):
|
||||
return 0
|
||||
elif a.getValue('uid') < b.getValue('uid'):
|
||||
return -1
|
||||
else:
|
||||
return 1
|
||||
elif a.getValue('sn') < b.getValue('sn'):
|
||||
elif a.getValue('givenName') < b.getValue('givenName'):
|
||||
return -1
|
||||
else:
|
||||
return 1
|
||||
elif a.getValue('givenname') < b.getValue('givenname'):
|
||||
elif a.getValue('sn') < b.getValue('sn'):
|
||||
return -1
|
||||
else:
|
||||
return 1
|
||||
|
@ -248,7 +248,9 @@ else:
|
||||
<th>
|
||||
<label class="fieldlabel" py:content="fields.labeleduri.label" />:
|
||||
</th>
|
||||
<td>${user.get("labeleduri")}</td>
|
||||
<td>
|
||||
<a href="${user.get('labeleduri')}">${user.get('labeleduri')}</a>
|
||||
</td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user