Fixes #2908: projects.
[edumed.git] / catalogue / admin.py
1 from django.contrib import admin
2 from .models import Attachment, Section, Lesson, LessonStub
3
4 class AttachmentInline(admin.TabularInline):
5     model = Attachment
6
7 class LessonAdmin(admin.ModelAdmin):
8     inlines = [AttachmentInline]
9     list_display = ['title', 'section', 'type']
10     list_filter = ['level', 'type']
11
12 admin.site.register(Section)
13 admin.site.register(Lesson, LessonAdmin)
14 admin.site.register(LessonStub)
15