From 064889eb9fc08bc439667c5d0384b12d13255782 Mon Sep 17 00:00:00 2001 From: Zhorken Date: Mon, 27 Sep 2010 02:59:48 -0400 Subject: [PATCH] Order Pokemon.stats by stat id. #366 --- pokedex/db/tables.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pokedex/db/tables.py b/pokedex/db/tables.py index 633d845..31b9445 100644 --- a/pokedex/db/tables.py +++ b/pokedex/db/tables.py @@ -893,7 +893,7 @@ Pokemon.habitat = association_proxy('pokemon_habitat', 'name') Pokemon.items = relation(PokemonItem, backref='pokemon') Pokemon.generation = relation(Generation, backref='pokemon') Pokemon.shape = relation(PokemonShape, backref='pokemon') -Pokemon.stats = relation(PokemonStat, backref='pokemon') +Pokemon.stats = relation(PokemonStat, backref='pokemon', order_by=PokemonStat.stat_id.asc()) Pokemon.types = relation(Type, secondary=PokemonType.__table__, order_by=PokemonType.slot.asc()) PokemonDexNumber.pokedex = relation(Pokedex) -- 2.7.4