~widelands-dev/widelands-website/django_staticfiles

« back to all changes in this revision

Viewing changes to wlevents/admin.py

  • Committer: franku
  • Date: 2016-12-13 18:28:51 UTC
  • mto: This revision was merged to the branch mainline in revision 443.
  • Revision ID: somal@arcor.de-20161213182851-bo5ebf8pdvw5beua
run the script

Show diffs side-by-side

added added

removed removed

Lines of Context:
4
4
from models import Event
5
5
from django.contrib import admin
6
6
 
 
7
 
7
8
class EventAdmin(admin.ModelAdmin):
8
 
    search_fields = [ "name" ]
9
 
    list_display = ["name", "start_date"]
10
 
    list_filter = [ "start_date" ]
 
9
    search_fields = ['name']
 
10
    list_display = ['name', 'start_date']
 
11
    list_filter = ['start_date']
11
12
 
12
13
admin.site.register(Event, EventAdmin)
13