d95d66dac8
We're lock-step with symposion, and upstream is dead. Vendor it.
22 lines
546 B
Python
22 lines
546 B
Python
from django.contrib import admin
|
|
|
|
from symposion.conference.models import Conference, Section
|
|
|
|
|
|
class SectionInline(admin.TabularInline):
|
|
model = Section
|
|
prepopulated_fields = {"slug": ("name",)}
|
|
extra = 1
|
|
|
|
|
|
class ConferenceAdmin(admin.ModelAdmin):
|
|
list_display = ("title", "start_date", "end_date")
|
|
inlines = [SectionInline, ]
|
|
|
|
|
|
admin.site.register(Conference, ConferenceAdmin)
|
|
admin.site.register(
|
|
Section,
|
|
prepopulated_fields={"slug": ("name",)},
|
|
list_display=("name", "conference", "start_date", "end_date")
|
|
)
|