[open-ils-commits] r119 - servres/trunk/conifer/syrup
svn at svn.open-ils.org
svn at svn.open-ils.org
Sun Jan 25 19:12:53 EST 2009
Author: artunit
Date: 2009-01-25 19:12:53 -0500 (Sun, 25 Jan 2009)
New Revision: 119
Modified:
servres/trunk/conifer/syrup/views.py
Log:
Modified: servres/trunk/conifer/syrup/views.py
===================================================================
--- servres/trunk/conifer/syrup/views.py 2009-01-25 23:43:53 UTC (rev 118)
+++ servres/trunk/conifer/syrup/views.py 2009-01-26 00:12:53 UTC (rev 119)
@@ -85,7 +85,8 @@
count = int(request.GET.get('count', 5))
if browse_option == 'instructors':
- paginator = Paginator(models.UserProfile.active_instructors(), count)
+ paginator = Paginator(models.UserProfile.active_instructors().
+ order_by('user__last_name'), count)
return g.render('instructors.xhtml', paginator=paginator,
page_num=page_num,
@@ -329,7 +330,7 @@
#item search - this will be expanded
item_query = get_query(query_string, ['title', 'author'])
#need to think about sort order here, probably better by author (will make sortable at display level)
- results_list = models.Item.objects.filter(item_query).order_by('-date_created')
+ results_list = models.Item.objects.filter(item_query).order_by('title')
results_len = len(results_list)
paginator = Paginator( results_list,
count)
@@ -351,7 +352,7 @@
instructor_list = instructor_results.order_by('user__last_name')[0:5]
instr_len = len(instructor_results)
else:
- results_list = models.Item.objects.order_by('-date_created')
+ results_list = models.Item.objects.order_by('title')
results_len = len(results_list)
paginator = Paginator( results_list,
count)
More information about the open-ils-commits
mailing list