<filename>apps/exams/migrations/0002_option_question.py
# Generated by Django 2.2.8 on 2020-04-08 21:24

import ckeditor_uploader.fields
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('exams', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Option',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('body', models.TextField()),
                ('is_answer', models.BooleanField(default=False)),
            ],
        ),
        migrations.CreateModel(
            name='Question',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('type', models.CharField(choices=[('1', 'MCQ(Single Option Correct)'), ('2', 'MCQ(Multiple Option Correct)'), ('3', 'Subjective')], default='1', max_length=1)),
                ('body', ckeditor_uploader.fields.RichTextUploadingField()),
                ('marks', models.FloatField(default=0, validators=[django.core.validators.MinValueValidator(0)])),
                ('negative_marks', models.FloatField(default=0.0, validators=[django.core.validators.MinValueValidator(0.0)])),
                ('exam', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='exams.Exam')),
                ('options', models.ManyToManyField(to='exams.Option')),
            ],
        ),
    ]

<filename>apps/exams/migrations/0002_option_question.py
# Generated by Django 2.2.8 on 2020-04-08 21:24

import ckeditor_uploader.fields
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion


class Migration(migrations.Migration):

    dependencies = [
        ('exams', '0001_initial'),
    ]

    operations = [
        migrations.CreateModel(
            name='Option',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('body', models.TextField()),
                ('is_answer', models.BooleanField(default=False)),
            ],
        ),
        migrations.CreateModel(
            name='Question',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('type', models.CharField(choices=[('1', 'MCQ(Single Option Correct)'), ('2', 'MCQ(Multiple Option Correct)'), ('3', 'Subjective')], default='1', max_length=1)),
                ('body', ckeditor_uploader.fields.RichTextUploadingField()),
                ('marks', models.FloatField(default=0, validators=[django.core.validators.MinValueValidator(0)])),
                ('negative_marks', models.FloatField(default=0.0, validators=[django.core.validators.MinValueValidator(0.0)])),
                ('exam', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='exams.Exam')),
                ('options', models.ManyToManyField(to='exams.Option')),
            ],
        ),
    ]

# Generated by Django 2.2.8 on 2020-04-08 21:24