from django.contrib import admin from .models import FreeTextAnswer, LLMGradedAnswer, MultipleChoiceAnswer, Question, Quiz admin.site.register(Quiz) class FreeTextAnswerInline(admin.StackedInline): model = FreeTextAnswer class MultipleChoiceAnswerInline(admin.StackedInline): model = MultipleChoiceAnswer class LLMGradedAnswerInline(admin.StackedInline): model = LLMGradedAnswer class QuestionAdmin(admin.ModelAdmin): inlines = [FreeTextAnswerInline, MultipleChoiceAnswerInline, LLMGradedAnswerInline] admin.site.register(Question, QuestionAdmin)