# Generated by Django 2.1.2 on 2018-12-28 15:52

from django.db import migrations, models
import django.db.models.deletion
import rounds.helpers


class Migration(migrations.Migration):

    dependencies = [
        ('users', '0005_judgeuser'),
        ('rounds', '0005_auto_20181227_1239'),
    ]

    operations = [
        migrations.CreateModel(
            name='Assessment',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('rough_notes', models.TextField(help_text="Add any rough notes here. Will NOT be counted in the team's score.", verbose_name='rough notes')),
                ('last_updated', models.DateTimeField(auto_now=True, verbose_name='last updated')),
                ('judge', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='users.Judge', verbose_name='judge')),
            ],
        ),
        migrations.CreateModel(
            name='AssessmentMark',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('mark', models.PositiveSmallIntegerField(help_text='The assessment mark cannot be greater than the rubric mark.', verbose_name='assessment mark')),
                ('assessment', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='rounds.Assessment', verbose_name='assessment')),
            ],
        ),
        migrations.CreateModel(
            name='Rubric',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('release', models.BooleanField(default=False, verbose_name='release rubric')),
                ('rubric_document', models.FileField(blank=True, help_text='Optional.', upload_to=rounds.helpers.rubric_upload_to, verbose_name='rubric as a document')),
            ],
        ),
        migrations.CreateModel(
            name='RubricMark',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('title', models.CharField(help_text='i.e. Presentation Skills', max_length=100, verbose_name='title')),
                ('max_mark', models.PositiveSmallIntegerField(help_text='What the mark is out of.', verbose_name='maximum possible mark')),
                ('rubric', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='rounds.Rubric', verbose_name='rubric')),
            ],
            options={
                'verbose_name': 'rubric mark',
            },
        ),
        migrations.AlterField(
            model_name='round',
            name='active',
            field=models.BooleanField(default=False, help_text='If True, delegates can submit files.', verbose_name='active'),
        ),
        migrations.AlterField(
            model_name='round',
            name='description',
            field=models.TextField(blank=True, help_text='Optional. Write a public description, that provides more information about the current round.', verbose_name='description'),
        ),
        migrations.AlterField(
            model_name='round',
            name='details_file',
            field=models.FileField(blank=True, help_text='Optional. Upload a public file, that provides more information about the current round.', upload_to=rounds.helpers.round_details_upload_to, verbose_name='file with details'),
        ),
        migrations.AlterField(
            model_name='round',
            name='expected_deadline',
            field=models.DateTimeField(help_text='NOTE: The round will not automatically close.', verbose_name='expected deadline'),
        ),
        migrations.AlterField(
            model_name='round',
            name='number',
            field=models.SmallIntegerField(unique=True, verbose_name='round number'),
        ),
        migrations.AlterField(
            model_name='round',
            name='survey_link',
            field=models.URLField(blank=True, help_text='Optional. Add a link to a survey to be shown when the  round is visible but not active (to delegates).', verbose_name='survey link'),
        ),
        migrations.AlterField(
            model_name='round',
            name='visible',
            field=models.BooleanField(default=False, help_text='If True, delegates can view the details of the round.', verbose_name='visible'),
        ),
        migrations.AlterField(
            model_name='submission',
            name='latest',
            field=models.BooleanField(help_text='If True, this file is the latest file from a team. ', verbose_name='latest file'),
        ),
        migrations.AddField(
            model_name='rubric',
            name='round',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='rounds.Round', verbose_name='round'),
        ),
        migrations.AddField(
            model_name='assessmentmark',
            name='rubric_mark',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='rounds.RubricMark'),
        ),
        migrations.AddField(
            model_name='assessment',
            name='rubric',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='rounds.Rubric', verbose_name='rubric'),
        ),
        migrations.AddField(
            model_name='assessment',
            name='team',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='users.Team', verbose_name='team'),
        ),
    ]
