alphabetical order on maintainers and packages

This commit is contained in:
Dusty Phillips 2008-11-15 15:42:33 -05:00
parent 2f9d725b02
commit 0dbde37b20
2 changed files with 2 additions and 1 deletions

View File

@ -14,7 +14,7 @@ def index(request):
'repos': Repo.objects.all(), 'arches': Arch.objects.all(), 'repos': Repo.objects.all(), 'arches': Arch.objects.all(),
'maintainers': [ 'maintainers': [
User(id=0, username="orphan", first_name="Orphans") User(id=0, username="orphan", first_name="Orphans")
] + list(User.objects.filter(is_active=True)) ] + list(User.objects.filter(is_active=True).order_by('username'))
} }
return render_to_response('devel/index.html', return render_to_response('devel/index.html',

View File

@ -144,6 +144,7 @@ class Package(models.Model):
objects = PackageManager() objects = PackageManager()
class Meta: class Meta:
db_table = 'packages' db_table = 'packages'
ordering = ('pkgname',)
#get_latest_by = 'last_update' #get_latest_by = 'last_update'
#ordering = ('-last_update',) #ordering = ('-last_update',)