mirror of
https://github.com/veekun/pokedex.git
synced 2024-08-20 18:16:34 +00:00
Make the VersionGroup.machines relationship into a backref
This commit is contained in:
parent
61ed3c4ccb
commit
97e15e3f08
1 changed files with 1 additions and 4 deletions
|
@ -1783,7 +1783,7 @@ LocationGameIndex.generation = relationship(Generation,
|
||||||
|
|
||||||
Machine.item = relationship(Item)
|
Machine.item = relationship(Item)
|
||||||
Machine.version_group = relationship(VersionGroup,
|
Machine.version_group = relationship(VersionGroup,
|
||||||
innerjoin=True, lazy='joined')
|
innerjoin=True, lazy='joined', backref='machines')
|
||||||
|
|
||||||
|
|
||||||
Move.changelog = relationship(MoveChangelog,
|
Move.changelog = relationship(MoveChangelog,
|
||||||
|
@ -2150,9 +2150,6 @@ VersionGroup.pokemon_move_methods = relationship(PokemonMoveMethod,
|
||||||
primaryjoin=and_(VersionGroup.id == VersionGroupPokemonMoveMethod.version_group_id),
|
primaryjoin=and_(VersionGroup.id == VersionGroupPokemonMoveMethod.version_group_id),
|
||||||
secondaryjoin=and_(PokemonMoveMethod.id == VersionGroupPokemonMoveMethod.pokemon_move_method_id),
|
secondaryjoin=and_(PokemonMoveMethod.id == VersionGroupPokemonMoveMethod.pokemon_move_method_id),
|
||||||
backref="version_groups")
|
backref="version_groups")
|
||||||
VersionGroup.machines = relationship(Machine,
|
|
||||||
innerjoin=True,
|
|
||||||
order_by=Machine.machine_number)
|
|
||||||
|
|
||||||
|
|
||||||
VersionGroupPokemonMoveMethod.version_group = relationship(VersionGroup,
|
VersionGroupPokemonMoveMethod.version_group = relationship(VersionGroup,
|
||||||
|
|
Loading…
Reference in a new issue