forked from 0x2620/pandora
timeline, frame are optional
This commit is contained in:
parent
b5682cf97c
commit
b3b5278f94
4 changed files with 8 additions and 8 deletions
|
@ -29,8 +29,8 @@ def render_poster(data, poster):
|
|||
series = data.get('isSeries', False)
|
||||
oxdb_id = data['oxdbId']
|
||||
imdb_id = data['id']
|
||||
frame = data['frame']
|
||||
timeline = data['timeline']
|
||||
frame = data.get('frame')
|
||||
timeline = data.get('timeline')
|
||||
|
||||
def get_oxdb_color(oxdb_id, series=False):
|
||||
i = int(round((int(oxdb_id[2:10], 16) * 762 / pow(2, 32))))
|
||||
|
|
|
@ -26,8 +26,8 @@ def render_poster(data, poster):
|
|||
director = u', '.join(data.get('director', []))
|
||||
director = ox.decode_html(director)
|
||||
year = str(data.get('year', ''))
|
||||
frame = data['frame']
|
||||
timeline = data['timeline']
|
||||
frame = data.get('frame')
|
||||
timeline = data.get('timeline')
|
||||
|
||||
poster_width = 704
|
||||
poster_height = 1024
|
||||
|
|
|
@ -23,8 +23,8 @@ static_root = os.path.join(os.path.dirname(__file__), 'data')
|
|||
def render_poster(data, poster):
|
||||
title = ox.decode_html(data.get('title', ''))
|
||||
id = data['id']
|
||||
frame = data['frame']
|
||||
timeline = data['timeline']
|
||||
frame = data.get('frame')
|
||||
timeline = data.get('timeline')
|
||||
|
||||
poster_width = 640
|
||||
poster_height = 1024
|
||||
|
|
|
@ -29,8 +29,8 @@ def render_poster(data, poster):
|
|||
series = data.get('isSeries', False)
|
||||
oxdb_id = data['oxdbId']
|
||||
imdb_id = data['id']
|
||||
frame = data['frame']
|
||||
timeline = data['timeline']
|
||||
frame = data.get('frame')
|
||||
timeline = data.get('timeline')
|
||||
|
||||
def get_oxdb_color(oxdb_id, series=False):
|
||||
i = int(round((int(oxdb_id[2:10], 16) * 762 / pow(2, 32))))
|
||||
|
|
Loading…
Reference in a new issue