On limite à 3 caractères la taille de l'abbréviation
This commit is contained in:
parent
bd968d55c1
commit
f7763e2e92
2 changed files with 21 additions and 1 deletions
20
elections/migrations/0024_alter_option_abbreviation.py
Normal file
20
elections/migrations/0024_alter_option_abbreviation.py
Normal file
|
@ -0,0 +1,20 @@
|
|||
# Generated by Django 3.2 on 2021-04-17 19:29
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
dependencies = [
|
||||
("elections", "0023_option_abbreviation"),
|
||||
]
|
||||
|
||||
operations = [
|
||||
migrations.AlterField(
|
||||
model_name="option",
|
||||
name="abbreviation",
|
||||
field=models.CharField(
|
||||
blank=True, max_length=3, verbose_name="abbréviation"
|
||||
),
|
||||
),
|
||||
]
|
|
@ -137,7 +137,7 @@ class Option(models.Model):
|
|||
Question, related_name="options", on_delete=models.CASCADE
|
||||
)
|
||||
text = TranslatedFieldWithFallback(models.TextField(_("texte"), blank=False))
|
||||
abbreviation = models.CharField(_("abbréviation"), max_length=8, blank=True)
|
||||
abbreviation = models.CharField(_("abbréviation"), max_length=3, blank=True)
|
||||
|
||||
winner = models.BooleanField(_("option gagnante"), default=False)
|
||||
voters = models.ManyToManyField(
|
||||
|
|
Loading…
Reference in a new issue