-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #235 from Studio-Yandex-Practicum/feature/create_m…
…ain_coordinator Добавил отметку главного координатора
- Loading branch information
Showing
5 changed files
with
60 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 33 additions & 0 deletions
33
src/bot/migrations/0004_alter_coordinator_options_coordinator_is_chief.py
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
# Generated by Django 4.2.4 on 2023-08-29 18:57 | ||
|
||
from django.db import migrations, models | ||
|
||
import bot.validators | ||
|
||
|
||
class Migration(migrations.Migration): | ||
"""Migrations for bot.""" | ||
|
||
dependencies = [ | ||
("bot", "0003_alter_coordinator_first_name_and_more"), | ||
] | ||
|
||
operations = [ | ||
migrations.AlterModelOptions( | ||
name="coordinator", | ||
options={ | ||
"ordering": ("-is_chief", "last_name"), | ||
"verbose_name": "Координатор", | ||
"verbose_name_plural": "Координаторы", | ||
}, | ||
), | ||
migrations.AddField( | ||
model_name="coordinator", | ||
name="is_chief", | ||
field=models.BooleanField( | ||
default=False, | ||
validators=[bot.validators.validate_is_chief], | ||
verbose_name="Главный", | ||
), | ||
), | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters