From 3cc87b94ad57cf484453341c041bcf06c31981d3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20Zapke-Gru=CC=88ndemann?= Date: Fri, 30 Dec 2011 01:54:52 +0100 Subject: Added filter, search and date hierarchy. --- sublab_project/news/admin.py | 3 +++ 1 file changed, 3 insertions(+) (limited to 'sublab_project/news') diff --git a/sublab_project/news/admin.py b/sublab_project/news/admin.py index ffead60..0a145f5 100644 --- a/sublab_project/news/admin.py +++ b/sublab_project/news/admin.py @@ -6,6 +6,9 @@ from news.models import News class NewsAdmin(admin.ModelAdmin): prepopulated_fields = {'slug': ('title',)} list_display = ('title', 'date_created', 'date_updated') + list_filter = ('author',) + search_fields = ['title', 'content'] + date_hierarchy = 'date_updated' def save_model(self, request, obj, form, change): if not obj.id: -- cgit v1.2.1