Ticket #2895: django.contrib.admin.views.main.py.diff

File django.contrib.admin.views.main.py.diff, 415 bytes (added by Ben Ford <ben.fordnz@…>, 18 years ago)

diff of the necessary changes to django.contrib.admin.views.main.py

Line 
1709,713c709
2< o_field = f.rel.to._meta.ordering[0]
3< if o_field[0] == '-':
4< self.order_type = 'desc'
5< o_field = o_field[1:]
6< rel_ordering = f.rel.to._meta.ordering and o_field or f.rel.to._meta.pk.column
7---
8> rel_ordering = f.rel.to._meta.ordering and f.rel.to._meta.ordering[0] or f.rel.to._meta.pk.column
Back to Top