1
0
mirror of https://gitlab.com/animath/si/plateforme.git synced 2025-12-13 03:55:15 +01:00

Drop django-address dependency and keep only street, zip code and city (/!\ Breaking commit, can't upgrade)

This commit is contained in:
Emmy D'Anello
2023-01-10 20:24:06 +01:00
parent f7eddd289b
commit 63a10c1be5
21 changed files with 197 additions and 448 deletions

View File

@@ -1,8 +1,9 @@
# Generated by Django 3.0.11 on 2021-01-22 18:26
# Generated by Django 3.2.13 on 2023-01-10 19:22
import datetime
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion
import django.utils.timezone
import participation.models
@@ -47,8 +48,8 @@ class Migration(migrations.Migration):
name='Passage',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('place', models.CharField(default='Non indiqué', help_text='Where the solution is presented?', max_length=255, verbose_name='place')),
('solution_number', models.PositiveSmallIntegerField(choices=[(1, 'Problem #1'), (2, 'Problem #2'), (3, 'Problem #3'), (4, 'Problem #4'), (5, 'Problem #5'), (6, 'Problem #6'), (7, 'Problem #7'), (8, 'Problem #8')], verbose_name='defended solution')),
('defender_penalties', models.PositiveSmallIntegerField(default=0, help_text='Number of penalties for the defender. The defender will loose a 0.5 coefficient per penalty.', verbose_name='penalties')),
],
options={
'verbose_name': 'passage',
@@ -61,6 +62,7 @@ class Migration(migrations.Migration):
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('round', models.PositiveSmallIntegerField(choices=[(1, 'Round 1'), (2, 'Round 2')], verbose_name='round')),
('bbb_url', models.CharField(blank=True, default='', help_text='The link of the BBB visio for this pool.', max_length=255, verbose_name='BigBlueButton URL')),
('results_available', models.BooleanField(default=False, help_text='Check this case when results become accessible to teams. They stay accessible to you. Only averages are given.', verbose_name='results available')),
],
options={
'verbose_name': 'pool',
@@ -73,11 +75,12 @@ class Migration(migrations.Migration):
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('problem', models.PositiveSmallIntegerField(choices=[(1, 'Problem #1'), (2, 'Problem #2'), (3, 'Problem #3'), (4, 'Problem #4'), (5, 'Problem #5'), (6, 'Problem #6'), (7, 'Problem #7'), (8, 'Problem #8')], verbose_name='problem')),
('final_solution', models.BooleanField(default=False, verbose_name='solution for the final tournament')),
('file', models.FileField(blank=True, default='', unique=True, upload_to=participation.models.get_solution_filename, verbose_name='file')),
('file', models.FileField(unique=True, upload_to=participation.models.get_solution_filename, verbose_name='file')),
],
options={
'verbose_name': 'solution',
'verbose_name_plural': 'solutions',
'ordering': ('participation__team__trigram', 'final_solution', 'problem'),
},
),
migrations.CreateModel(
@@ -85,11 +88,12 @@ class Migration(migrations.Migration):
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('type', models.PositiveSmallIntegerField(choices=[(1, 'opponent'), (2, 'reporter')])),
('file', models.FileField(blank=True, default='', unique=True, upload_to=participation.models.get_synthesis_filename, verbose_name='file')),
('file', models.FileField(unique=True, upload_to=participation.models.get_synthesis_filename, verbose_name='file')),
],
options={
'verbose_name': 'synthesis',
'verbose_name_plural': 'syntheses',
'ordering': ('passage__pool__round', 'type'),
},
),
migrations.CreateModel(
@@ -113,8 +117,10 @@ class Migration(migrations.Migration):
('name', models.CharField(max_length=255, unique=True, verbose_name='name')),
('date_start', models.DateField(default=datetime.date.today, verbose_name='start')),
('date_end', models.DateField(default=datetime.date.today, verbose_name='end')),
('place', models.CharField(max_length=255, verbose_name='place')),
('max_teams', models.PositiveSmallIntegerField(default=9, verbose_name='max team count')),
('price', models.PositiveSmallIntegerField(default=21, verbose_name='price')),
('remote', models.BooleanField(default=False, verbose_name='remote')),
('inscription_limit', models.DateTimeField(default=django.utils.timezone.now, verbose_name='limit date for registrations')),
('solution_limit', models.DateTimeField(default=django.utils.timezone.now, verbose_name='limit date to upload solutions')),
('solutions_draw', models.DateTimeField(default=django.utils.timezone.now, verbose_name='random draw for solutions')),
@@ -129,4 +135,17 @@ class Migration(migrations.Migration):
'verbose_name_plural': 'tournaments',
},
),
migrations.CreateModel(
name='Tweak',
fields=[
('id', models.AutoField(auto_created=True, primary_key=True, serialize=False, verbose_name='ID')),
('diff', models.IntegerField(help_text='Score to add/remove on the final score', verbose_name='difference')),
('participation', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='tweaks', to='participation.participation', verbose_name='participation')),
('pool', models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, to='participation.pool', verbose_name='passage')),
],
options={
'verbose_name': 'tweak',
'verbose_name_plural': 'tweaks',
},
),
]