blob: d34f269f537dafd721af50733c9a158b4f603ab8 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
|
from rest_framework import serializers
from yaksh.models import Question, Quiz, QuestionPaper, AnswerPaper
class QuestionSerializer(serializers.ModelSerializer):
class Meta:
model = Question
fields = '__all__'
class QuizSerializer(serializers.ModelSerializer):
class Meta:
model = Quiz
fields = '__all__'
class QuestionPaperSerializer(serializers.ModelSerializer):
class Meta:
model = QuestionPaper
fields = '__all__'
class AnswerPaperSerializer(serializers.ModelSerializer):
class Meta:
model = AnswerPaper
fields = '__all__'
|