Ordering the display items alphabetically in Django-Admin

Viewed 18125

I am now able to display the item I want using the list_display[] but I would like them to displayed alphabetically. How do you make that the list_display is ordered alphabetically?

Example in Django-admin:

class PersonAdmin(admin.ModelAdmin):
    list_display = ('upper_case_name',)

    def upper_case_name(self, obj):
      return ("%s %s" % (obj.first_name, obj.last_name)).upper()
    upper_case_name.short_description = 'Name'

How to alter this to display alphabetically? Need some help on this...

2 Answers
Related