support id in query
This commit is contained in:
parent
778639def8
commit
767176fa09
1 changed files with 15 additions and 12 deletions
|
@ -9,6 +9,9 @@ import ox
|
||||||
|
|
||||||
def find(info, guess=True):
|
def find(info, guess=True):
|
||||||
q = Imdb.objects.all()
|
q = Imdb.objects.all()
|
||||||
|
if 'id' in info:
|
||||||
|
q = q.filter(imdb=info['id'])
|
||||||
|
else:
|
||||||
if 'seriesTitle' in info:
|
if 'seriesTitle' in info:
|
||||||
info['title'] = info['seriesTitle']
|
info['title'] = info['seriesTitle']
|
||||||
for key in Imdb.keys:
|
for key in Imdb.keys:
|
||||||
|
|
Loading…
Reference in a new issue