from rest_framework import serializers

from .models import *


class CoordinatorSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    FName = serializers.CharField(max_length=100, required=False)
    LName = serializers.CharField(max_length=100, required=False)
    Phone = serializers.CharField(max_length=100, required=False)
    Office = serializers.CharField(max_length=100, required=False)
    Email = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        # Once the request data has been validated, we can create a todo item instance in the database
        return Coordinator.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            FName=validated_data.get('FName'),
            LName=validated_data.get('LName'),
            Phone=validated_data.get('Phone'),
            Office=validated_data.get('Office'),
            Email=validated_data.get('Email')
        )

    def update(self, instance, validated_data):
        # Once the request data has been validated, we can update the todo item instance in the database
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.FName = validated_data.get('FName', instance.FName)
        instance.LName = validated_data.get('LName', instance.LName)
        instance.Phone = validated_data.get('Phone', instance.Phone)
        instance.Office = validated_data.get('Office', instance.Office)
        instance.Email = validated_data.get('Email', instance.Email)
        instance.save()
        return instance

    class Meta:
        model = Coordinator
        fields = (
            'ModelID',
            'CourseID',
            'FName',
            'LName',
            'Phone',
            'Office',
            'Email'
        )


class InfoSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    GradeNotes = serializers.CharField(max_length=5000, required=False)
    Examination = serializers.CharField(max_length=5000, required=False)
    CourseDescription = serializers.CharField(max_length=5000, required=False)
    UseCalc = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Info.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            GradeNotes=validated_data.get('GradeNotes'),
            Examination=validated_data.get('Examination'),
            CourseDescription=validated_data.get('CourseDescription'),
            UseCalc=validated_data.get('UseCalc')
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.GradeNotes = validated_data.get('GradeNotes', instance.GradeNotes)
        instance.Examination = validated_data.get('Examination', instance.Examination)
        instance.CourseDescription = validated_data.get('CourseDescription', instance.CourseDescription)
        instance.UseCalc = validated_data.get('UseCalc', instance.UseCalc)
        instance.save()
        return instance

    class Meta:
        model = Info
        fields = (
            'ModelID',
            'CourseID',
            'GradeNotes',
            'Examination',
            'CourseDescription',
            'UseCalc'
        )


class GradeDeterminationSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    Component = serializers.CharField(max_length=100, required=False)
    OutcomeEvaluated = serializers.CharField(max_length=100, required=False)
    Weight = serializers.IntegerField(required=False)

    def create(self, validated_data):
        # Once the request data has been validated, we can create a todo item instance in the database
        return GradeDetermination.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            Component=validated_data.get('Component'),
            OutcomeEvaluated=validated_data.get('OutcomeEvaluated'),
            Weight=validated_data.get('Weight'),
        )

    def update(self, instance, validated_data):
        # Once the request data has been validated, we can update the todo item instance in the database
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.Component = validated_data.get('Component', instance.Component)
        instance.OutcomeEvaluated = validated_data.get('OutcomeEvaluated', instance.OutcomeEvaluated)
        instance.Weight = validated_data.get('Weight', instance.Weight)
        instance.save()
        return instance

    class Meta:
        model = GradeDetermination
        fields = (
            'ModelID',
            'CourseID',
            'Component',
            'OutcomeEvaluated',
            'Weight'
        )


class OutcomeSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    OutcomeNum = serializers.IntegerField(required=False)  # removed max_length=100
    Description = serializers.CharField(max_length=500, required=False)  # Changed max_length to 500
    GraduateAttribute = serializers.CharField(max_length=100, required=False)
    InstructionLvl = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Outcome.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            OutcomeNum=validated_data.get('OutcomeNum'),
            Description=validated_data.get('Description'),
            GraduateAttribute=validated_data.get('GraduateAttribute'),
            InstructionLvl=validated_data.get('InstructionLvl'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.OutcomeNum = validated_data.get('OutcomeNum', instance.OutcomeNum)
        instance.Description = validated_data.get('Description', instance.Description)
        instance.GraduateAttribute = validated_data.get('GraduateAttribute', instance.GraduateAttribute)
        instance.InstructionLvl = validated_data.get('InstructionLvl', instance.InstructionLvl)
        instance.save()
        return instance

    class Meta:
        model = Outcome
        fields = (
            'ModelID',
            'CourseID',
            'OutcomeNum',
            'Description',
            'GraduateAttribute',
            'InstructionLvl'
        )


class TimetableSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    SectionNum = serializers.CharField(max_length=100, required=False)
    Days = serializers.CharField(max_length=100, required=False)
    Time = serializers.CharField(max_length=100, required=False)
    Location = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Timetable.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            SectionNum=validated_data.get('SectionNum'),
            Days=validated_data.get('Days'),
            Time=validated_data.get('Time'),
            Location=validated_data.get('Location'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.SectionNum = validated_data.get('SectionNum', instance.SectionNum)
        instance.Days = validated_data.get('Days', instance.Days)
        instance.Time = validated_data.get('Time', instance.Time)
        instance.Location = validated_data.get('Location', instance.Location)
        instance.save()
        return instance

    class Meta:
        model = Timetable
        fields = (
            'ModelID',
            'CourseID',
            'SectionNum',
            'Days',
            'Time',
            'Location'
        )


class GradeDistributionSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    LowerLimit = serializers.IntegerField(required=False)  # removed max_length = 100
    UpperLimit = serializers.IntegerField(required=False)  # removed max_length = 100
    LetterGrade = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return GradeDistribution.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            LowerLimit=validated_data.get('LowerLimit'),
            UpperLimit=validated_data.get('UpperLimit'),
            LetterGrade=validated_data.get('LetterGrade'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.LowerLimit = validated_data.get('LowerLimit', instance.LowerLimit)
        instance.UpperLimit = validated_data.get('UpperLimit', instance.UpperLimit)
        instance.LetterGrade = validated_data.get('LetterGrade', instance.LetterGrade)
        instance.save()
        return instance

    class Meta:
        model = GradeDistribution
        fields = (
            'ModelID',
            'CourseID',
            'LowerLimit',
            'UpperLimit',
            'LetterGrade'
        )


class LectureSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    LectureNum = serializers.CharField(max_length=100, required=False)
    FName = serializers.CharField(max_length=100, required=False)
    LName = serializers.CharField(max_length=100, required=False)
    Phone = serializers.CharField(max_length=100, required=False)
    Office = serializers.CharField(max_length=100, required=False)
    Email = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Lecture.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            LectureNum=validated_data.get('LectureNum'),
            FName=validated_data.get('FName'),
            LName=validated_data.get('LName'),
            Phone=validated_data.get('Phone'),
            Office=validated_data.get('Office'),
            Email=validated_data.get('Email'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.LectureNum = validated_data.get('LectureNum', instance.LectureNum)
        instance.FName = validated_data.get('FName', instance.FName)
        instance.LName = validated_data.get('LName', instance.LName)
        instance.Phone = validated_data.get('Phone', instance.Phone)
        instance.Office = validated_data.get('Office', instance.Office)
        instance.Email = validated_data.get('Email', instance.Email)
        instance.save()
        return instance

    class Meta:
        model = Lecture
        fields = (
            'ModelID',
            'CourseID',
            'LectureNum',
            'FName',
            'LName',
            'Phone',
            'Office',
            'Email'
        )


class TutorialSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    TutorialNum = serializers.CharField(max_length=100, required=False)  # Changed Tutorial Num to CharField
    FName = serializers.CharField(max_length=100, required=False)  # Changed FName to CharField
    LName = serializers.CharField(max_length=100, required=False)
    Phone = serializers.CharField(max_length=100, required=False)
    Office = serializers.CharField(max_length=100, required=False)
    Email = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Tutorial.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            TutorialNum=validated_data.get('TutorialNum'),
            FName=validated_data.get('FName'),
            LName=validated_data.get('LName'),
            Phone=validated_data.get('Phone'),
            Office=validated_data.get('Office'),
            Email=validated_data.get('Email'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.TutorialNum = validated_data.get('TutorialNum', instance.TutorialNum)
        instance.FName = validated_data.get('FName', instance.FName)
        instance.LName = validated_data.get('LName', instance.LName)
        instance.Phone = validated_data.get('Phone', instance.Phone)
        instance.Office = validated_data.get('Office', instance.Office)
        instance.Email = validated_data.get('Email', instance.Email)
        instance.save()
        return instance

    class Meta:
        model = Tutorial
        fields = (
            'ModelID',
            'CourseID',
            'TutorialNum',
            'FName',
            'LName',
            'Phone',
            'Office',
            'Email'
        )


class CourseSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    CourseHours = serializers.CharField(max_length=100, required=False)  # Changed CourseHours to CharField
    CourseName = serializers.CharField(max_length=100, required=False)  # Changed CourseName to CharField
    CalenderRefrence = serializers.CharField(max_length=100, required=False)
    AcademicCredit = serializers.IntegerField(required=False)  # Changed AcademicCredit to IntegerField
    DateCreated = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Course.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            CourseHours=validated_data.get('CourseHours'),
            CourseName=validated_data.get('CourseName'),
            CalenderRefrence=validated_data.get('CalenderRefrence'),
            AcademicCredit=validated_data.get('AcademicCredit'),
            DateCreated=validated_data.get('DateCreated'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.CourseHours = validated_data.get('CourseHours', instance.CourseHours)
        instance.CourseName = validated_data.get('CourseName', instance.CourseName)
        instance.CalenderRefrence = validated_data.get('CalenderRefrence', instance.CalenderRefrence)
        instance.AcademicCredit = validated_data.get('AcademicCredit', instance.AcademicCredit)
        instance.DateCreated = validated_data.get('DateCreated', instance.DateCreated)
        instance.save()
        return instance

    class Meta:
        model = Course
        fields = (
            'ModelID',
            'CourseID',
            'CourseHours',
            'CourseName',
            'CalenderRefrence',
            'AcademicCredit',
            'DateCreated'
        )


class TextbookSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    TITLE = serializers.CharField(max_length=100, required=False)
    Publisher = serializers.CharField(max_length=100, required=False)
    Author = serializers.CharField(max_length=100, required=False)
    Edition = serializers.CharField(max_length=100, required=False)
    type = serializers.CharField(max_length=100, required=False)

    def create(self, validated_data):
        return Textbook.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            TITLE=validated_data.get('TITLE'),
            Publisher=validated_data.get('Publisher'),
            Author=validated_data.get('Author'),
            Edition=validated_data.get('Edition'),
            type=validated_data.get('type'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.TITLE = validated_data.get('TITLE', instance.TITLE)
        instance.Publisher = validated_data.get('Publisher', instance.Publisher)
        instance.Author = validated_data.get('Author', instance.Author)
        instance.Edition = validated_data.get('Edition', instance.Edition)
        instance.type = validated_data.get('type', instance.type)
        instance.save()
        return instance

    class Meta:
        model = Textbook
        fields = (
            'ModelID',
            'CourseID',
            'TITLE',
            'Publisher',
            'Author',
            'Edition',
            'type'
        )


class AuWeightSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    Category = serializers.CharField(max_length=100, required=True)
    AU = serializers.IntegerField(required=False)

    def create(self, validated_data):
        return AuWeight.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            Category=validated_data.get('Category'),
            AU=validated_data.get('AU'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.Category = validated_data.get('Category', instance.Category)
        instance.AU = validated_data.get('AU', instance.AU)
        instance.save()
        return instance

    class Meta:
        model = AuWeight
        fields = (
            'ModelID',
            'CourseID',
            'Category',
            'AU'
        )


class ContentCategorySerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    CategoryType = serializers.CharField(max_length=100, required=True)
    Element = serializers.CharField(max_length=100, required=True)

    def create(self, validated_data):
        return ContentCategory.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            CategoryType=validated_data.get('CategoryType'),
            Element=validated_data.get('Element'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.CategoryType = validated_data.get('CategoryType', instance.CategoryType)
        instance.Element = validated_data.get('Element', instance.Element)
        instance.save()
        return instance

    class Meta:
        model = ContentCategory
        fields = (
            'ModelID',
            'CourseID',
            'CategoryType',
            'Element'
        )


class LabSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    LabNum = serializers.CharField(max_length=100, required=True)
    NumberOfLabs = serializers.IntegerField(required=False)
    LabType = serializers.CharField(max_length=100, required=True)
    SafetyExamined = serializers.CharField(max_length=100, required=True)
    SafetyTaught = serializers.CharField(max_length=100, required=True)
    FName = serializers.CharField(max_length=100, required=True)
    LName = serializers.CharField(max_length=100, required=True)
    Phone = serializers.CharField(max_length=100, required=True)
    Office = serializers.CharField(max_length=100, required=True)
    Email = serializers.CharField(max_length=100, required=True)

    def create(self, validated_data):
        return Lab.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            LabNum=validated_data.get('LabNum'),
            NumberOfLabs=validated_data.get('NumberOfLabs'),
            LabType=validated_data.get('LabType'),
            SafetyExamined=validated_data.get('SafetyExamined'),
            SafetyTaught=validated_data.get('SafetyTaught'),
            FName=validated_data.get('FName'),
            LName=validated_data.get('LName'),
            Phone=validated_data.get('Phone'),
            Office=validated_data.get('Office'),
            Email=validated_data.get('Email'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.LabNum = validated_data.get('LabNum', instance.LabNum)
        instance.NumberOfLabs = validated_data.get('NumberOfLabs', instance.NumberOfLabs)
        instance.LabType = validated_data.get('LabType', instance.LabType)
        instance.SafetyExamined = validated_data.get('SafetyExamined', instance.SafetyExamined)
        instance.SafetyTaught = validated_data.get('SafetyTaught', instance.SafetyTaught)
        instance.FName = validated_data.get('FName', instance.FName)
        instance.LName = validated_data.get('LName', instance.LName)
        instance.Phone = validated_data.get('Phone', instance.Phone)
        instance.Office = validated_data.get('Office', instance.Office)
        instance.Email = validated_data.get('Email', instance.Email)
        instance.save()
        return instance

    class Meta:
        model = Lab
        fields = (
            'ModelID',
            'CourseID',
            'LabNum',
            'NumberOfLabs',
            'LabType',
            'SafetyExamined',
            'SafetyTaught',
            'FName',
            'LName',
            'Phone',
            'Office',
            'Email'
        )


class SectionSerializer(serializers.ModelSerializer):
    # ModelID = serializers.CharField(max_length=100, required=True)
    CourseID = serializers.CharField(max_length=100, required=True)
    SectionNumber = serializers.CharField(max_length=100, required=False)
    Students = serializers.IntegerField(required=False)
    Hours = serializers.IntegerField(required=False)
    type = serializers.CharField(max_length=100, required=True)

    def create(self, validated_data):
        return Section.objects.create(
            ModelID=validated_data.get('ModelID'),
            CourseID=validated_data.get('CourseID'),
            SectionNumber=validated_data.get('SectionNumber'),
            Students=validated_data.get('Students'),
            Hours=validated_data.get('Hours'),
            type=validated_data.get('type'),
        )

    def update(self, instance, validated_data):
        instance.ModelID = validated_data.get('ModelID', instance.ModelID)
        instance.CourseID = validated_data.get('CourseID', instance.CourseID)
        instance.SectionNumber = validated_data.get('SectionNumber', instance.SectionNumber)
        instance.Students = validated_data.get('Students', instance.Students)
        instance.Hours = validated_data.get('Hours', instance.Hours)
        instance.type = validated_data.get('type', instance.type)
        instance.save()
        return instance

    class Meta:
        model = Section
        fields = (
            'ModelID',
            'CourseID',
            'SectionNumber',
            'Students',
            'Hours',
            'type'
        )

[((206, 258), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (227, 258), False, 'from rest_framework import serializers\n'), ((271, 324), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (292, 324), False, 'from rest_framework import serializers\n'), ((337, 390), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (358, 390), False, 'from rest_framework import serializers\n'), ((403, 456), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (424, 456), False, 'from rest_framework import serializers\n'), ((470, 523), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (491, 523), False, 'from rest_framework import serializers\n'), ((536, 589), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (557, 589), False, 'from rest_framework import serializers\n'), ((2191, 2243), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (2212, 2243), False, 'from rest_framework import serializers\n'), ((2261, 2315), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(5000)', 'required': '(False)'}), '(max_length=5000, required=False)\n', (2282, 2315), False, 'from rest_framework import serializers\n'), ((2334, 2388), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(5000)', 'required': '(False)'}), '(max_length=5000, required=False)\n', (2355, 2388), False, 'from rest_framework import serializers\n'), ((2413, 2467), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(5000)', 'required': '(False)'}), '(max_length=5000, required=False)\n', (2434, 2467), False, 'from rest_framework import serializers\n'), ((2482, 2535), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (2503, 2535), False, 'from rest_framework import serializers\n'), ((3936, 3988), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (3957, 3988), False, 'from rest_framework import serializers\n'), ((4005, 4058), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (4026, 4058), False, 'from rest_framework import serializers\n'), ((4082, 4135), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (4103, 4135), False, 'from rest_framework import serializers\n'), ((4149, 4189), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (4173, 4189), False, 'from rest_framework import serializers\n'), ((5625, 5677), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (5646, 5677), False, 'from rest_framework import serializers\n'), ((5695, 5735), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (5719, 5735), False, 'from rest_framework import serializers\n'), ((5780, 5833), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(500)', 'required': '(False)'}), '(max_length=500, required=False)\n', (5801, 5833), False, 'from rest_framework import serializers\n'), ((5887, 5940), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (5908, 5940), False, 'from rest_framework import serializers\n'), ((5962, 6015), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (5983, 6015), False, 'from rest_framework import serializers\n'), ((7456, 7508), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (7477, 7508), False, 'from rest_framework import serializers\n'), ((7526, 7579), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (7547, 7579), False, 'from rest_framework import serializers\n'), ((7591, 7644), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (7612, 7644), False, 'from rest_framework import serializers\n'), ((7656, 7709), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (7677, 7709), False, 'from rest_framework import serializers\n'), ((7725, 7778), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (7746, 7778), False, 'from rest_framework import serializers\n'), ((9075, 9127), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (9096, 9127), False, 'from rest_framework import serializers\n'), ((9145, 9185), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (9169, 9185), False, 'from rest_framework import serializers\n'), ((9231, 9271), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (9255, 9271), False, 'from rest_framework import serializers\n'), ((9318, 9371), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (9339, 9371), False, 'from rest_framework import serializers\n'), ((10597, 10649), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (10618, 10649), False, 'from rest_framework import serializers\n'), ((10667, 10720), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (10688, 10720), False, 'from rest_framework import serializers\n'), ((10733, 10786), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (10754, 10786), False, 'from rest_framework import serializers\n'), ((10799, 10852), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (10820, 10852), False, 'from rest_framework import serializers\n'), ((10865, 10918), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (10886, 10918), False, 'from rest_framework import serializers\n'), ((10932, 10985), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (10953, 10985), False, 'from rest_framework import serializers\n'), ((10998, 11051), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (11019, 11051), False, 'from rest_framework import serializers\n'), ((12609, 12661), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (12630, 12661), False, 'from rest_framework import serializers\n'), ((12680, 12733), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (12701, 12733), False, 'from rest_framework import serializers\n'), ((12783, 12836), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (12804, 12836), False, 'from rest_framework import serializers\n'), ((12879, 12932), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (12900, 12932), False, 'from rest_framework import serializers\n'), ((12945, 12998), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (12966, 12998), False, 'from rest_framework import serializers\n'), ((13012, 13065), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (13033, 13065), False, 'from rest_framework import serializers\n'), ((13078, 13131), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (13099, 13131), False, 'from rest_framework import serializers\n'), ((14695, 14747), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (14716, 14747), False, 'from rest_framework import serializers\n'), ((14766, 14819), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (14787, 14819), False, 'from rest_framework import serializers\n'), ((14873, 14926), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (14894, 14926), False, 'from rest_framework import serializers\n'), ((14985, 15038), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (15006, 15038), False, 'from rest_framework import serializers\n'), ((15060, 15100), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (15084, 15100), False, 'from rest_framework import serializers\n'), ((15161, 15214), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (15182, 15214), False, 'from rest_framework import serializers\n'), ((16819, 16871), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (16840, 16871), False, 'from rest_framework import serializers\n'), ((16884, 16937), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (16905, 16937), False, 'from rest_framework import serializers\n'), ((16954, 17007), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (16975, 17007), False, 'from rest_framework import serializers\n'), ((17021, 17074), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (17042, 17074), False, 'from rest_framework import serializers\n'), ((17089, 17142), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (17110, 17142), False, 'from rest_framework import serializers\n'), ((17154, 17207), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (17175, 17207), False, 'from rest_framework import serializers\n'), ((18630, 18682), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (18651, 18682), False, 'from rest_framework import serializers\n'), ((18698, 18750), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (18719, 18750), False, 'from rest_framework import serializers\n'), ((18760, 18800), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (18784, 18800), False, 'from rest_framework import serializers\n'), ((19783, 19835), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (19804, 19835), False, 'from rest_framework import serializers\n'), ((19855, 19907), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (19876, 19907), False, 'from rest_framework import serializers\n'), ((19922, 19974), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (19943, 19974), False, 'from rest_framework import serializers\n'), ((21013, 21065), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21034, 21065), False, 'from rest_framework import serializers\n'), ((21079, 21131), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21100, 21131), False, 'from rest_framework import serializers\n'), ((21151, 21191), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (21175, 21191), False, 'from rest_framework import serializers\n'), ((21206, 21258), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21227, 21258), False, 'from rest_framework import serializers\n'), ((21280, 21332), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21301, 21332), False, 'from rest_framework import serializers\n'), ((21352, 21404), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21373, 21404), False, 'from rest_framework import serializers\n'), ((21417, 21469), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21438, 21469), False, 'from rest_framework import serializers\n'), ((21482, 21534), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21503, 21534), False, 'from rest_framework import serializers\n'), ((21547, 21599), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21568, 21599), False, 'from rest_framework import serializers\n'), ((21613, 21665), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21634, 21665), False, 'from rest_framework import serializers\n'), ((21678, 21730), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (21699, 21730), False, 'from rest_framework import serializers\n'), ((23953, 24005), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (23974, 24005), False, 'from rest_framework import serializers\n'), ((24026, 24079), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(False)'}), '(max_length=100, required=False)\n', (24047, 24079), False, 'from rest_framework import serializers\n'), ((24095, 24135), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (24119, 24135), False, 'from rest_framework import serializers\n'), ((24148, 24188), 'rest_framework.serializers.IntegerField', 'serializers.IntegerField', ([], {'required': '(False)'}), '(required=False)\n', (24172, 24188), False, 'from rest_framework import serializers\n'), ((24200, 24252), 'rest_framework.serializers.CharField', 'serializers.CharField', ([], {'max_length': '(100)', 'required': '(True)'}), '(max_length=100, required=True)\n', (24221, 24252), False, 'from rest_framework import serializers\n')]