1
0
mirror of https://github.com/django/django.git synced 2025-10-23 21:59:11 +00:00

Fixed #30259 -- Fixed crash of admin views when properties don't have admin_order_field attribute.

This commit is contained in:
Mariusz Felisiak
2019-04-01 15:11:54 +02:00
committed by GitHub
parent 93daed25a4
commit 7cbcf2e2cb
3 changed files with 6 additions and 2 deletions

View File

@@ -104,7 +104,7 @@ class ArticleAdmin(admin.ModelAdmin):
list_display = (
'content', 'date', callable_year, 'model_year', 'modeladmin_year',
'model_year_reversed', 'section', lambda obj: obj.title,
'order_by_expression', 'model_property_year',
'order_by_expression', 'model_property_year', 'model_month',
)
list_editable = ('section',)
list_filter = ('date', 'section')