From 6ea9cb06493561c7626aebe0ac36e473851bd51b Mon Sep 17 00:00:00 2001 From: Razmig Sarkissian Date: Wed, 15 May 2024 22:53:50 +0200 Subject: [PATCH 1/3] update tournament --- ...46_tournament_publish_brackets_and_more.py | 33 +++++++++++++++++++ tournaments/models/tournament.py | 4 +++ 2 files changed, 37 insertions(+) create mode 100644 tournaments/migrations/0046_tournament_publish_brackets_and_more.py diff --git a/tournaments/migrations/0046_tournament_publish_brackets_and_more.py b/tournaments/migrations/0046_tournament_publish_brackets_and_more.py new file mode 100644 index 0000000..0d6d808 --- /dev/null +++ b/tournaments/migrations/0046_tournament_publish_brackets_and_more.py @@ -0,0 +1,33 @@ +# Generated by Django 4.2.11 on 2024-05-15 20:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('tournaments', '0045_alter_purchase_identifier'), + ] + + operations = [ + migrations.AddField( + model_name='tournament', + name='publish_brackets', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='tournament', + name='publish_groupStages', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='tournament', + name='publish_summons', + field=models.BooleanField(default=False), + ), + migrations.AddField( + model_name='tournament', + name='publish_teams', + field=models.BooleanField(default=False), + ), + ] diff --git a/tournaments/models/tournament.py b/tournaments/models/tournament.py index 6ceb20d..044374d 100644 --- a/tournaments/models/tournament.py +++ b/tournaments/models/tournament.py @@ -37,6 +37,10 @@ class Tournament(models.Model): is_deleted = models.BooleanField(default=False) is_canceled = models.BooleanField(default=False) additional_estimation_duration = models.IntegerField(default=0) + publish_teams = models.BooleanField(default=False) + publish_summons = models.BooleanField(default=False) + publish_groupStages = models.BooleanField(default=False) + publish_brackets = models.BooleanField(default=False) def __str__(self): if self.name: From 797f2d2adf140f2672cebcfd28562edd7eb18d8d Mon Sep 17 00:00:00 2001 From: Razmig Sarkissian Date: Wed, 15 May 2024 23:11:12 +0200 Subject: [PATCH 2/3] update tournament --- ...upstages_tournament_publish_group_stages.py | 18 ++++++++++++++++++ tournaments/models/tournament.py | 2 +- 2 files changed, 19 insertions(+), 1 deletion(-) create mode 100644 tournaments/migrations/0047_rename_publish_groupstages_tournament_publish_group_stages.py diff --git a/tournaments/migrations/0047_rename_publish_groupstages_tournament_publish_group_stages.py b/tournaments/migrations/0047_rename_publish_groupstages_tournament_publish_group_stages.py new file mode 100644 index 0000000..ae9813a --- /dev/null +++ b/tournaments/migrations/0047_rename_publish_groupstages_tournament_publish_group_stages.py @@ -0,0 +1,18 @@ +# Generated by Django 4.2.11 on 2024-05-15 21:10 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('tournaments', '0046_tournament_publish_brackets_and_more'), + ] + + operations = [ + migrations.RenameField( + model_name='tournament', + old_name='publish_groupStages', + new_name='publish_group_stages', + ), + ] diff --git a/tournaments/models/tournament.py b/tournaments/models/tournament.py index 044374d..4e53b29 100644 --- a/tournaments/models/tournament.py +++ b/tournaments/models/tournament.py @@ -39,7 +39,7 @@ class Tournament(models.Model): additional_estimation_duration = models.IntegerField(default=0) publish_teams = models.BooleanField(default=False) publish_summons = models.BooleanField(default=False) - publish_groupStages = models.BooleanField(default=False) + publish_group_stages = models.BooleanField(default=False) publish_brackets = models.BooleanField(default=False) def __str__(self): From 40569012557b4790fb72c6c84fdbbd99f89a56e4 Mon Sep 17 00:00:00 2001 From: Razmig Sarkissian Date: Thu, 16 May 2024 09:43:47 +0200 Subject: [PATCH 3/3] remove unused field tournament --- ...remove_tournament_group_stage_court_count.py | 17 +++++++++++++++++ tournaments/models/tournament.py | 2 +- 2 files changed, 18 insertions(+), 1 deletion(-) create mode 100644 tournaments/migrations/0048_remove_tournament_group_stage_court_count.py diff --git a/tournaments/migrations/0048_remove_tournament_group_stage_court_count.py b/tournaments/migrations/0048_remove_tournament_group_stage_court_count.py new file mode 100644 index 0000000..d402645 --- /dev/null +++ b/tournaments/migrations/0048_remove_tournament_group_stage_court_count.py @@ -0,0 +1,17 @@ +# Generated by Django 4.2.11 on 2024-05-16 07:43 + +from django.db import migrations + + +class Migration(migrations.Migration): + + dependencies = [ + ('tournaments', '0047_rename_publish_groupstages_tournament_publish_group_stages'), + ] + + operations = [ + migrations.RemoveField( + model_name='tournament', + name='group_stage_court_count', + ), + ] diff --git a/tournaments/models/tournament.py b/tournaments/models/tournament.py index 4e53b29..d90484f 100644 --- a/tournaments/models/tournament.py +++ b/tournaments/models/tournament.py @@ -24,7 +24,7 @@ class Tournament(models.Model): federal_category = models.IntegerField(default=FederalCategory.MEN, choices=FederalCategory.choices) # optional ? federal_level_category = models.IntegerField(default=FederalLevelCategory.P100, choices=FederalLevelCategory.choices) federal_age_category = models.IntegerField(default=FederalAgeCategory.SENIOR, choices=FederalAgeCategory.choices) - group_stage_court_count = models.IntegerField(null=True, blank=True) + #group_stage_court_count = models.IntegerField(null=True, blank=True) #seed_count = models.IntegerField(default=0) closed_registration_date = models.DateTimeField(null=True, blank=True) group_stage_additional_qualified = models.IntegerField(default=0)