bornhack-website/src/program/admin.py

43 lines
688 B
Python
Raw Normal View History

2016-07-13 17:13:47 +00:00
from django.contrib import admin
from .models import Event, Speaker, EventType, EventInstance, EventLocation
@admin.register(EventLocation)
class EventInstanceAdmin(admin.ModelAdmin):
pass
2016-07-13 19:44:09 +00:00
@admin.register(EventInstance)
class EventInstanceAdmin(admin.ModelAdmin):
pass
2016-07-13 19:44:09 +00:00
@admin.register(EventType)
class EventTypeAdmin(admin.ModelAdmin):
pass
@admin.register(Speaker)
class SpeakerAdmin(admin.ModelAdmin):
pass
class SpeakerInline(admin.StackedInline):
model = Speaker.events.through
2016-07-13 19:44:09 +00:00
@admin.register(Event)
class EventAdmin(admin.ModelAdmin):
2016-07-13 20:37:20 +00:00
list_display = [
'title',
'event_type',
]
inlines = [
SpeakerInline
]
2016-07-13 19:44:09 +00:00
2016-07-13 17:13:47 +00:00