comparison gpp/donations/models.py @ 350:2177a71b680c

Fixing #173; display donors in order by date, ascending on the main view.
author Brian Neal <bgneal@gmail.com>
date Wed, 02 Mar 2011 02:47:15 +0000
parents 75ea1a8be7f2
children
comparison
equal deleted inserted replaced
349:a43add8af83d 350:2177a71b680c
28 if month is None: 28 if month is None:
29 month = today.month 29 month = today.month
30 30
31 qs = self.filter(payment_date__year=year, 31 qs = self.filter(payment_date__year=year,
32 payment_date__month=month, 32 payment_date__month=month,
33 test_ipn=settings.DONATIONS_DEBUG).select_related('user') 33 test_ipn=settings.DONATIONS_DEBUG).order_by(
34 'payment_date').select_related('user')
34 35
35 gross = decimal.Decimal() 36 gross = decimal.Decimal()
36 net = decimal.Decimal() 37 net = decimal.Decimal()
37 donations = [] 38 donations = []
38 for donation in qs: 39 for donation in qs: