Revision ffb5cca1 snf-astakos-app/astakos/im/management/commands/user-group-list.py

b/snf-astakos-app/astakos/im/management/commands/user-group-list.py
35 35
from synnefo.webproject.management.commands import ListCommand
36 36

  
37 37

  
38
def users_count(group):
39
    return group.user_set.count()
40

  
41

  
38 42
class Command(ListCommand):
39 43
    help = "List available groups"
40 44

  
41 45
    object_class = Group
42 46

  
43
    def users_count(group):
44
        return group.user_set.count()
45

  
46 47
    FIELDS = {
47 48
        'id': ('id', 'The id of the group'),
48 49
        'name': ('name', 'The name of the group'),

Also available in: Unified diff