From 86c48cc4314b593ee6c9136490a72433a5dca1e2 Mon Sep 17 00:00:00 2001 From: Dan McGee Date: Wed, 6 Jul 2011 13:17:29 -0500 Subject: Add a few more valid package sort fields Just for fun and for people that know what they are doing. Signed-off-by: Dan McGee --- packages/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/views.py b/packages/views.py index 3d9032e6..1f2a38d3 100644 --- a/packages/views.py +++ b/packages/views.py @@ -279,7 +279,9 @@ def search(request, page=None): 'search_form': form, 'current_query': current_query } - allowed_sort = ["arch", "repo", "pkgname", "last_update", "flag_date"] + allowed_sort = ["arch", "repo", "pkgname", "pkgname", + "compressed_size", "installed_size", + "build_date", "last_update", "flag_date"] allowed_sort += ["-" + s for s in allowed_sort] sort = request.GET.get('sort', None) # TODO: sorting by multiple fields makes using a DB index much harder -- cgit v1.2.3-54-g00ecf