From baeca40a4c876b76e5945b57530a116c17df4e9d Mon Sep 17 00:00:00 2001 From: Gabriel Augendre Date: Thu, 9 Mar 2023 18:06:52 +0000 Subject: [PATCH] Fix damage pet --- .../migrations/0042_alter_pet_damage.py | 17 +++++++++++++++++ src/character/migrations/max_migration.txt | 2 +- src/character/models/pet.py | 2 +- 3 files changed, 19 insertions(+), 2 deletions(-) create mode 100644 src/character/migrations/0042_alter_pet_damage.py diff --git a/src/character/migrations/0042_alter_pet_damage.py b/src/character/migrations/0042_alter_pet_damage.py new file mode 100644 index 0000000..87e1b70 --- /dev/null +++ b/src/character/migrations/0042_alter_pet_damage.py @@ -0,0 +1,17 @@ +# Generated by Django 4.1.7 on 2023-03-09 18:05 + +from django.db import migrations, models + + +class Migration(migrations.Migration): + dependencies = [ + ("character", "0041_pet"), + ] + + operations = [ + migrations.AlterField( + model_name="pet", + name="damage", + field=models.CharField(max_length=20, verbose_name="dégâts"), + ), + ] diff --git a/src/character/migrations/max_migration.txt b/src/character/migrations/max_migration.txt index f529b90..f728bc4 100644 --- a/src/character/migrations/max_migration.txt +++ b/src/character/migrations/max_migration.txt @@ -1 +1 @@ -0041_pet +0042_alter_pet_damage diff --git a/src/character/models/pet.py b/src/character/models/pet.py index 6a1329b..aa839b3 100644 --- a/src/character/models/pet.py +++ b/src/character/models/pet.py @@ -26,7 +26,7 @@ class Pet(models.Model): ) modifier_wisdom = models.IntegerField(verbose_name="modificateur sagesse") modifier_charisma = models.IntegerField(verbose_name="modificateur charisme") - damage = models.PositiveIntegerField(verbose_name="dégâts") + damage = models.CharField(max_length=20, verbose_name="dégâts") initiative = models.PositiveIntegerField(verbose_name="initiative") defense = models.PositiveIntegerField(verbose_name="défense") attack = models.PositiveIntegerField(verbose_name="attaque")