Changeset d7f5dc5 for asadb


Ignore:
Timestamp:
Dec 12, 2011, 12:07:34 AM (14 years ago)
Author:
Alex Dehnert <adehnert@…>
Branches:
master, space-access, stable, stage, test-hooks
Children:
1f4cc3c
Parents:
a836fd4
git-author:
Alex Dehnert <adehnert@…> (12/12/11 00:07:34)
git-committer:
Alex Dehnert <adehnert@…> (12/12/11 00:07:34)
Message:

Consistent ordering in dump_group_perms.py

File:
1 edited

Legend:

Unmodified
Added
Removed
  • asadb/util/dump_group_perms.py

    rf1506a6 rd7f5dc5  
    1717def dump_group_perms():
    1818    groups = []
    19     for group in django.contrib.auth.models.Group.objects.all():
     19    for group in django.contrib.auth.models.Group.objects.order_by('name'):
    2020        groups.append((group.name, [
    21             perm_tuple(perm) for perm in group.permissions.all()
     21            perm_tuple(perm) for perm in group.permissions.order_by('content_type__app_label', 'content_type__model', 'codename', )
    2222        ]))
    2323    return groups
Note: See TracChangeset for help on using the changeset viewer.