mirror of
https://github.com/PokeAPI/pokeapi
synced 2024-11-10 06:04:18 +00:00
Removing ultrabeast column and only updating is_legendary and is_mythical
This commit is contained in:
parent
d13b2f3b7d
commit
25e026cc6a
6 changed files with 811 additions and 829 deletions
|
@ -1280,8 +1280,7 @@ def _build_pokemons():
|
|||
forms_switchable=bool(int(info[15])),
|
||||
is_legendary=bool(int(info[16])),
|
||||
is_mythical=bool(int(info[17])),
|
||||
is_ultra_beast=bool(int(info[18])),
|
||||
order=int(info[19]),
|
||||
order=int(info[18]),
|
||||
)
|
||||
|
||||
build_generic((PokemonSpecies,), "pokemon_species.csv", csv_record_to_objects)
|
||||
|
|
File diff suppressed because it is too large
Load diff
|
@ -1,15 +1,10 @@
|
|||
# Generated by Django 2.1.11 on 2020-08-09 23:12
|
||||
# Generated by Django 2.1.11 on 2020-08-15 05:10
|
||||
|
||||
from django.db import migrations, models
|
||||
|
||||
|
||||
class Migration(migrations.Migration):
|
||||
|
||||
replaces = [
|
||||
("pokemon_v2", "0006_pokemonspecies_is_legendary"),
|
||||
("pokemon_v2", "0007_auto_20200809_2028"),
|
||||
]
|
||||
|
||||
dependencies = [
|
||||
("pokemon_v2", "0005_auto_20200709_1930"),
|
||||
]
|
||||
|
@ -25,9 +20,4 @@ class Migration(migrations.Migration):
|
|||
name="is_mythical",
|
||||
field=models.BooleanField(default=False),
|
||||
),
|
||||
migrations.AddField(
|
||||
model_name="pokemonspecies",
|
||||
name="is_ultra_beast",
|
||||
field=models.BooleanField(default=False),
|
||||
),
|
||||
]
|
|
@ -1639,8 +1639,6 @@ class PokemonSpecies(
|
|||
|
||||
is_mythical = models.BooleanField(default=False)
|
||||
|
||||
is_ultra_beast = models.BooleanField(default=False)
|
||||
|
||||
hatch_counter = models.IntegerField()
|
||||
|
||||
has_gender_differences = models.BooleanField(default=False)
|
||||
|
|
|
@ -2986,7 +2986,6 @@ class PokemonSpeciesDetailSerializer(serializers.ModelSerializer):
|
|||
"is_baby",
|
||||
"is_legendary",
|
||||
"is_mythical",
|
||||
"is_ultra_beast",
|
||||
"hatch_counter",
|
||||
"has_gender_differences",
|
||||
"forms_switchable",
|
||||
|
|
|
@ -1464,7 +1464,6 @@ class APIData:
|
|||
forms_switchable=False,
|
||||
is_legendary=False,
|
||||
is_mythical=False,
|
||||
is_ultra_beast=False,
|
||||
order=1,
|
||||
):
|
||||
|
||||
|
@ -1504,7 +1503,6 @@ class APIData:
|
|||
forms_switchable=forms_switchable,
|
||||
is_legendary=is_legendary,
|
||||
is_mythical=is_mythical,
|
||||
is_ultra_beast=is_ultra_beast,
|
||||
order=order,
|
||||
)
|
||||
pokemon_species.save()
|
||||
|
@ -4568,9 +4566,7 @@ class APITests(APIData, APITestCase):
|
|||
self.assertEqual(response.data["is_baby"], pokemon_species.is_baby)
|
||||
self.assertEqual(response.data["is_legendary"], pokemon_species.is_legendary)
|
||||
self.assertEqual(response.data["is_mythical"], pokemon_species.is_mythical)
|
||||
self.assertEqual(
|
||||
response.data["is_ultra_beast"], pokemon_species.is_ultra_beast
|
||||
)
|
||||
|
||||
self.assertEqual(response.data["hatch_counter"], pokemon_species.hatch_counter)
|
||||
self.assertEqual(
|
||||
response.data["has_gender_differences"],
|
||||
|
|
Loading…
Reference in a new issue