# Generated by Django 3.1 on 2021-02-10 06:58
import timezone_field

import display.fields.my_pickled_object_field
from django.db import migrations, models
import django.utils.timezone
import django_countries.fields
import guardian.mixins
import phonenumber_field.modelfields
from display.fields.my_pickled_object_field import MyPickledObjectField


class Migration(migrations.Migration):

    initial = True

    dependencies = [
        ('auth', '0012_alter_user_first_name_max_length'),
    ]

    operations = [
        migrations.CreateModel(
            name='Aeroplane',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('registration', models.CharField(max_length=20)),
                ('colour', models.CharField(blank=True, max_length=40)),
                ('type', models.CharField(blank=True, max_length=50)),
                ('picture', models.ImageField(blank=True, null=True, upload_to='images/aircraft/')),
            ],
        ),
        migrations.CreateModel(
            name='Club',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=200)),
                ('country', django_countries.fields.CountryField(blank=True, max_length=2)),
                ('logo', models.ImageField(blank=True, null=True, upload_to='images/clubs/')),
            ],
        ),
        migrations.CreateModel(
            name='Contest',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('summary_score_sorting_direction', models.CharField(choices=[('desc', 'Descending'), ('asc', 'Ascending')], default='asc', help_text='Whether the lowest (ascending) or highest (ascending) score is the best result', max_length=50)),
                ('name', models.CharField(max_length=100, unique=True)),
                ('time_zone', timezone_field.fields.TimeZoneField()),
                ('latitude', models.FloatField(default=0, help_text='Approximate location of contest, used for global map display')),
                ('longitude', models.FloatField(default=0, help_text='Approximate location of contest, used for global map display')),
                ('start_time', models.DateTimeField(help_text='The start time of the contest. Used for sorting. All navigation tasks should ideally be within this time interval.')),
                ('finish_time', models.DateTimeField(help_text='The finish time of the contest. Used for sorting. All navigation tasks should ideally be within this time interval.')),
                ('is_public', models.BooleanField(default=False)),
            ],
            options={
                'ordering': ('-start_time', '-finish_time'),
            },
        ),
        migrations.CreateModel(
            name='Contestant',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('adaptive_start', models.BooleanField(default=False, help_text='If true, takeoff time and minutes to starting point is ignored. Start time is set to the closest minute to the time crossing the starting line. This is typically used for a case where it is difficult to control the start time because of external factors such as ATC.')),
                ('takeoff_time', models.DateTimeField(help_text='The time the take of gate (if it exists) should be crossed. Otherwise it is the time power should be applied')),
                ('minutes_to_starting_point', models.FloatField(default=5, help_text='The number of minutes from the take-off time until the starting point')),
                ('finished_by_time', models.DateTimeField(help_text='The time it is expected that the navigation task has finished and landed (used among other things for knowing when the tracker is busy). Is also used for the gate time for the landing gate')),
                ('air_speed', models.FloatField(default=70, help_text='The planned airspeed for the contestant')),
                ('contestant_number', models.PositiveIntegerField(help_text='A unique number for the contestant in this navigation task')),
                ('tracking_service', models.CharField(choices=[('traccar', 'Traccar')], default='traccar', help_text="Supported tracking services: (('traccar', 'Traccar'),)", max_length=30)),
                ('tracker_device_id', models.CharField(blank=True, help_text='ID of physical tracking device that will be brought into the plane', max_length=100)),
                ('tracker_start_time', models.DateTimeField(help_text='When the tracker is handed to the contestant, can have no changes to the route (e.g. wind and timing) after this.')),
                ('competition_class_longform', models.CharField(blank=True, help_text='The class of the contestant, e.g. beginner, professional, et cetera', max_length=100, null=True)),
                ('competition_class_shortform', models.CharField(blank=True, help_text='The abbreviated class of the contestant, e.g. beginner, professional, et cetera', max_length=100, null=True)),
                ('predefined_gate_times', display.fields.my_pickled_object_field.MyPickledObjectField(blank=True, default=None, editable=False, help_text='Dictionary of gates and their starting times (with time zone)', null=True)),
                ('wind_speed', models.FloatField(default=0, help_text='The navigation test wind speed. This is used to calculate gate times if these are not predefined.')),
                ('wind_direction', models.FloatField(default=0, help_text='The navigation test wind direction. This is used to calculate gate times if these are not predefined.')),
            ],
            options={
                'ordering': ('takeoff_time',),
            },
        ),
        migrations.CreateModel(
            name='Crew',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
            ],
        ),
        migrations.CreateModel(
            name='GateScore',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default='', max_length=100)),
                ('extended_gate_width', models.FloatField(default=0, help_text='For SP it is 2 (1 nm each side), for tp with procedure turn it is 6')),
                ('bad_crossing_extended_gate_penalty', models.FloatField(default=200)),
                ('graceperiod_before', models.FloatField(default=3)),
                ('graceperiod_after', models.FloatField(default=3)),
                ('maximum_penalty', models.FloatField(default=100)),
                ('penalty_per_second', models.FloatField(default=2)),
                ('missed_penalty', models.FloatField(default=100)),
                ('bad_course_crossing_penalty', models.FloatField(default=0)),
                ('missed_procedure_turn_penalty', models.FloatField(default=200)),
                ('backtracking_after_steep_gate_grace_period_seconds', models.FloatField(default=0)),
                ('backtracking_after_gate_grace_period_nm', models.FloatField(default=0.5)),
            ],
        ),
        migrations.CreateModel(
            name='GateScoreOverride',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('for_gate_types', display.fields.my_pickled_object_field.MyPickledObjectField(default=list, editable=False, help_text='List of gates types (eg. tp, secret, sp) that should be overridden (all lower case)')),
                ('checkpoint_grace_period_before', models.FloatField(blank=True, default=None, help_text='The time before a checkpoint that no penalties are awarded', null=True)),
                ('checkpoint_grace_period_after', models.FloatField(blank=True, default=None, help_text='The time after a checkpoint that no penalties are awarded', null=True)),
                ('checkpoint_penalty_per_second', models.FloatField(blank=True, default=None, help_text='The number of points awarded per second outside of the grace period', null=True)),
                ('checkpoint_maximum_penalty', models.FloatField(blank=True, default=None, help_text='The maximum number of penalty points awarded for checkpoint timing', null=True)),
                ('checkpoint_not_found', models.FloatField(blank=True, default=None, help_text='The penalty for missing a checkpoint', null=True)),
                ('missing_procedure_turn_penalty', models.FloatField(blank=True, default=None, help_text='The penalty for missing a procedure turn', null=True)),
                ('bad_course_penalty', models.FloatField(blank=True, default=None, help_text='A amount of points awarded for crossing the gate in the wrong direction (e.g. for landing or takeoff)', null=True)),
                ('bad_crossing_extended_gate_penalty', models.FloatField(blank=True, default=None, help_text='The penalty awarded when crossing the extended gate in the wrong direction (typically used for start gate)', null=True)),
            ],
        ),
        migrations.CreateModel(
            name='NavigationTask',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=200)),
                ('start_time', models.DateTimeField(help_text='The start time of the navigation test. Not really important, but nice to have')),
                ('finish_time', models.DateTimeField(help_text='The finish time of the navigation test. Not really important, but nice to have')),
                ('is_public', models.BooleanField(default=False, help_text='The navigation test is only viewable by unauthenticated users or users without object permissions if this is True')),
                ('wind_speed', models.FloatField(default=0, help_text='The navigation test wind speed. This is used to calculate gate times if these are not predefined.')),
                ('wind_direction', models.FloatField(default=0, help_text='The navigation test wind direction. This is used to calculate gate times if these are not predefined.')),
                ('minutes_to_starting_point', models.FloatField(default=5, help_text='The number of minutes from the take-off time until the starting point')),
                ('minutes_to_landing', models.FloatField(default=5, help_text='The number of minutes from the finish point to the contestant should have landed')),
                ('contest', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.contest')),
                ('gate_score_override', models.ManyToManyField(blank=True, to='display.GateScoreOverride')),
            ],
            options={
                'ordering': ('start_time', 'finish_time'),
            },
        ),
        migrations.CreateModel(
            name='Person',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('first_name', models.CharField(max_length=200)),
                ('last_name', models.CharField(max_length=200)),
                ('email', models.EmailField(max_length=254, unique=True)),
                ('phone', phonenumber_field.modelfields.PhoneNumberField(blank=True, max_length=128, null=True, region=None)),
                ('app_tracking_id', models.CharField(editable=False, max_length=28)),
                ('app_aircraft_registration', models.CharField(blank=True, default='', max_length=100)),
                ('picture', models.ImageField(blank=True, null=True, upload_to='images/people/')),
                ('biography', models.TextField(blank=True)),
                ('country', django_countries.fields.CountryField(blank=True, max_length=2)),
            ],
        ),
        migrations.CreateModel(
            name='Route',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=200)),
                ('use_procedure_turns', models.BooleanField(blank=True, default=True)),
                ('rounded_corners', models.BooleanField(blank=True, default=False)),
                ('waypoints', display.fields.my_pickled_object_field.MyPickledObjectField(default=list, editable=False)),
                ('takeoff_gate', display.fields.my_pickled_object_field.MyPickledObjectField(default=None, editable=False, null=True)),
                ('landing_gate', display.fields.my_pickled_object_field.MyPickledObjectField(default=None, editable=False, null=True)),
            ],
        ),
        migrations.CreateModel(
            name='Task',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('summary_score_sorting_direction', models.CharField(choices=[('desc', 'Descending'), ('asc', 'Ascending')], default='asc', help_text='Whether the lowest (ascending) or highest (ascending) score is the best result', max_length=50)),
                ('name', models.CharField(max_length=100)),
                ('heading', models.CharField(max_length=100)),
                ('contest', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.contest')),
            ],
        ),
        migrations.CreateModel(
            name='TaskTest',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=100)),
                ('heading', models.CharField(max_length=100)),
                ('sorting', models.CharField(choices=[('desc', 'Descending'), ('asc', 'Ascending')], default='asc', help_text='Whether the lowest (ascending) or highest (ascending) score is the best result', max_length=50)),
                ('index', models.IntegerField(help_text='The index of the task when displayed as columns in a table. Indexes are sorted in ascending order to determine column order')),
                ('task', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.task')),
            ],
            options={
                'unique_together': {('name', 'task')},
            },
        ),
        migrations.CreateModel(
            name='Team',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('logo', models.ImageField(blank=True, null=True, upload_to='images/teams/')),
                ('country', django_countries.fields.CountryField(blank=True, max_length=2)),
                ('aeroplane', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='display.aeroplane')),
                ('club', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='display.club')),
                ('crew', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='display.crew')),
            ],
        ),
        migrations.CreateModel(
            name='TraccarCredentials',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('server_name', models.CharField(max_length=100)),
                ('protocol', models.CharField(default='http', max_length=10)),
                ('address', models.CharField(default='traccar:8082', max_length=100)),
                ('token', models.CharField(max_length=100)),
            ],
            options={
                'verbose_name': 'Traccar credentials',
            },
        ),
        migrations.CreateModel(
            name='TrackScoreOverride',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('bad_course_grace_time', models.FloatField(blank=True, default=None, help_text='The number of seconds a bad course can be tolerated before generating a penalty', null=True)),
                ('bad_course_penalty', models.FloatField(blank=True, default=None, help_text='A amount of points awarded for a bad course', null=True)),
                ('bad_course_maximum_penalty', models.FloatField(blank=True, default=None, help_text='A amount of points awarded for a bad course', null=True)),
                ('prohibited_zone_penalty', models.FloatField(default=200, help_text='Penalty for entering prohibited zone such as controlled airspace or other prohibited areas')),
                ('corridor_width', models.FloatField(blank=True, default=None, help_text='The width of the ANR corridor', null=True)),
                ('corridor_grace_time', models.FloatField(blank=True, default=None, help_text='The grace time of the ANR corridor', null=True)),
                ('corridor_outside_penalty', models.FloatField(blank=True, default=None, help_text='The penalty awarded for leaving the ANR corridor', null=True)),
                ('corridor_maximum_penalty', models.FloatField(blank=True, default=None, help_text='The maximum penalty for leaving the corridor', null=True)),
                ('navigation_task', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='display.navigationtask')),
            ],
        ),
        migrations.AddField(
            model_name='task',
            name='default_sorting',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='default_sort', to='display.tasktest'),
        ),
        migrations.CreateModel(
            name='Scorecard',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(default='default', max_length=100, unique=True)),
                ('calculator', models.IntegerField(choices=[(0, 'Precision'), (1, 'ANR Corridor')], default=0, help_text='Supported calculator types')),
                ('task_type', MyPickledObjectField(default=list)),
                ('use_procedure_turns', models.BooleanField(blank=True, default=True)),
                ('backtracking_penalty', models.FloatField(default=200)),
                ('backtracking_bearing_difference', models.FloatField(default=90)),
                ('backtracking_grace_time_seconds', models.FloatField(default=5)),
                ('backtracking_maximum_penalty', models.FloatField(default=-1, help_text='Negative numbers means the maximum is ignored')),
                ('below_minimum_altitude_penalty', models.FloatField(default=500)),
                ('below_minimum_altitude_maximum_penalty', models.FloatField(default=500)),
                ('prohibited_zone_penalty', models.FloatField(default=200, help_text='Penalty for entering prohibited zone such as controlled airspace or other prohibited areas')),
                ('corridor_width', models.FloatField(default=0.3, help_text='The corridor width for ANR tasks')),
                ('corridor_grace_time', models.IntegerField(default=5, help_text='The corridor grace time for ANR tasks')),
                ('corridor_outside_penalty', models.FloatField(default=3, help_text='The penalty awarded for leaving the ANR corridor')),
                ('corridor_maximum_penalty', models.FloatField(default=-1, help_text='The maximum penalty for leaving the corridor')),
                ('finish_point_gate_score', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='finish', to='display.gatescore')),
                ('landing_gate_score', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='landing', to='display.gatescore')),
                ('secret_gate_score', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='secret', to='display.gatescore')),
                ('starting_point_gate_score', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='starting', to='display.gatescore')),
                ('takeoff_gate_score', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='takeoff', to='display.gatescore')),
                ('turning_point_gate_score', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, related_name='turning_point', to='display.gatescore')),
            ],
        ),
        migrations.CreateModel(
            name='Prohibited',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('name', models.CharField(max_length=200)),
                ('path', display.fields.my_pickled_object_field.MyPickledObjectField(default=list, editable=False)),
                ('type', models.CharField(blank=True, default='', max_length=100)),
                ('route', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.route')),
            ],
        ),
        migrations.AddField(
            model_name='navigationtask',
            name='route',
            field=models.OneToOneField(on_delete=django.db.models.deletion.PROTECT, to='display.route'),
        ),
        migrations.AddField(
            model_name='navigationtask',
            name='scorecard',
            field=models.ForeignKey(help_text='Reference to an existing scorecard name. Currently existing scorecards: <function NavigationTask.<lambda> at 0x7f109802de18>', on_delete=django.db.models.deletion.PROTECT, to='display.scorecard'),
        ),
        migrations.AddField(
            model_name='navigationtask',
            name='track_score_override',
            field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='display.trackscoreoverride'),
        ),
        migrations.AddField(
            model_name='gatescoreoverride',
            name='navigation_task',
            field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.CASCADE, to='display.navigationtask'),
        ),
        migrations.AddField(
            model_name='crew',
            name='member1',
            field=models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, related_name='crewmember_one', to='display.person'),
        ),
        migrations.AddField(
            model_name='crew',
            name='member2',
            field=models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.PROTECT, related_name='crewmember_two', to='display.person'),
        ),
        migrations.CreateModel(
            name='ContestTeam',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('air_speed', models.FloatField(default=70, help_text='The planned airspeed for the contestant')),
                ('tracking_service', models.CharField(choices=[('traccar', 'Traccar')], default='traccar', help_text="Supported tracking services: (('traccar', 'Traccar'),)", max_length=30)),
                ('tracker_device_id', models.CharField(blank=True, help_text='ID of physical tracking device that will be brought into the plane', max_length=100)),
                ('contest', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.contest')),
                ('team', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.team')),
            ],
            options={
                'unique_together': {('contest', 'team')},
            },
        ),
        migrations.CreateModel(
            name='ContestantTrack',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('score_log', display.fields.my_pickled_object_field.MyPickledObjectField(default=list, editable=False)),
                ('score_per_gate', display.fields.my_pickled_object_field.MyPickledObjectField(default=dict, editable=False)),
                ('score', models.FloatField(default=0)),
                ('current_state', models.CharField(default='Waiting...', max_length=200)),
                ('current_leg', models.CharField(default='', max_length=100)),
                ('last_gate', models.CharField(default='', max_length=100)),
                ('last_gate_time_offset', models.FloatField(default=0)),
                ('past_starting_gate', models.BooleanField(default=False)),
                ('past_finish_gate', models.BooleanField(default=False)),
                ('calculator_finished', models.BooleanField(default=False)),
                ('gate_actual_times', display.fields.my_pickled_object_field.MyPickledObjectField(default=dict, editable=False)),
                ('contestant', models.OneToOneField(on_delete=django.db.models.deletion.CASCADE, to='display.contestant')),
            ],
        ),
        migrations.AddField(
            model_name='contestant',
            name='gate_score_override',
            field=models.ManyToManyField(to='display.GateScoreOverride'),
        ),
        migrations.AddField(
            model_name='contestant',
            name='navigation_task',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.navigationtask'),
        ),
        migrations.AddField(
            model_name='contestant',
            name='team',
            field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.team'),
        ),
        migrations.AddField(
            model_name='contestant',
            name='track_score_override',
            field=models.ForeignKey(null=True, on_delete=django.db.models.deletion.SET_NULL, to='display.trackscoreoverride'),
        ),
        migrations.AddField(
            model_name='contest',
            name='contest_teams',
            field=models.ManyToManyField(blank=True, through='display.ContestTeam', to='display.Team'),
        ),
        migrations.CreateModel(
            name='MyUser',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('password', models.CharField(max_length=128, verbose_name='password')),
                ('last_login', models.DateTimeField(blank=True, null=True, verbose_name='last login')),
                ('is_superuser', models.BooleanField(default=False, help_text='Designates that this user has all permissions without explicitly assigning them.', verbose_name='superuser status')),
                ('first_name', models.CharField(blank=True, max_length=30, verbose_name='first name')),
                ('last_name', models.CharField(blank=True, max_length=30, verbose_name='last name')),
                ('email', models.EmailField(max_length=255, unique=True, verbose_name='email address')),
                ('is_staff', models.BooleanField(default=False, help_text='Designates whether the user can log into this admin site.', verbose_name='staff status')),
                ('is_active', models.BooleanField(default=True, help_text='Designates whether this user should be treated as active.  Unselect this instead of deleting accounts.', verbose_name='active')),
                ('date_joined', models.DateTimeField(default=django.utils.timezone.now, verbose_name='date joined')),
                ('is_verified', models.BooleanField(default=False, help_text='Designates whether this user has completed the email verification process to allow login.', verbose_name='verified')),
                ('groups', models.ManyToManyField(blank=True, help_text='The groups this user belongs to. A user will get all permissions granted to each of their groups.', related_name='user_set', related_query_name='user', to='auth.Group', verbose_name='groups')),
                ('person', models.ForeignKey(blank=True, null=True, on_delete=django.db.models.deletion.SET_NULL, to='display.person')),
                ('user_permissions', models.ManyToManyField(blank=True, help_text='Specific permissions for this user.', related_name='user_set', related_query_name='user', to='auth.Permission', verbose_name='user permissions')),
            ],
            options={
                'verbose_name': 'user',
                'verbose_name_plural': 'users',
                'abstract': False,
            },
            bases=(models.Model, guardian.mixins.GuardianUserMixin),
        ),
        migrations.CreateModel(
            name='TeamTestScore',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('points', models.FloatField()),
                ('task_test', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.tasktest')),
                ('team', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='display.team')),
            ],
            options={
                'unique_together': {('team', 'task_test')},
            },
        ),
        migrations.CreateModel(
            name='TaskSummary',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('points', models.FloatField()),
                ('task', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.task')),
                ('team', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='display.team')),
            ],
            options={
                'unique_together': {('team', 'task')},
            },
        ),
        migrations.AlterUniqueTogether(
            name='task',
            unique_together={('name', 'contest')},
        ),
        migrations.CreateModel(
            name='ContestSummary',
            fields=[
                ('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
                ('points', models.FloatField()),
                ('contest', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='display.contest')),
                ('team', models.ForeignKey(on_delete=django.db.models.deletion.PROTECT, to='display.team')),
            ],
            options={
                'unique_together': {('team', 'contest')},
            },
        ),
        migrations.AlterUniqueTogether(
            name='contestant',
            unique_together={('navigation_task', 'contestant_number')},
        ),
    ]
