1
0
Fork 0
mirror of https://github.com/veekun/pokedex.git synced 2024-08-20 18:16:34 +00:00

Added support for type: prefix and forme lookup.

This commit is contained in:
Eevee 2009-08-23 16:27:13 -07:00
parent 238022485a
commit 909e61cc97
2 changed files with 70 additions and 12 deletions

View file

@ -67,7 +67,12 @@ def command_lookup(name):
print "Fuzzy-matched:"
for result in results:
print "%s: %s" % (result.object.__tablename__, result.object.name),
if hasattr(result.object, 'full_name'):
name = result.object.full_name
else:
name = result.object.name
print "%s: %s" % (result.object.__tablename__, name),
if result.language:
print "(%s in %s)" % (result.name, result.language)
else: