fix per py3 (tmdb videolibrarytools, generictools)

This commit is contained in:
Alhaziel
2020-02-15 11:42:18 +01:00
parent 3272766ef0
commit 7b3eb1e366
3 changed files with 8 additions and 7 deletions

View File

@@ -398,13 +398,13 @@ def set_infoLabels_item(item, seekTmdb=True, idioma_busqueda=def_lang, lock=None
if temporada:
# Actualizar datos
__leer_datos(otmdb_global)
item.infoLabels['title'] = temporada['name'] if temporada.has_key('name') else ''
if temporada.has_key('overview') and temporada['overview']:
item.infoLabels['title'] = temporada['name'] if 'name' in temporada else ''
if 'overview' in temporada and temporada['overview']:
item.infoLabels['plot'] = temporada['overview']
if temporada.has_key('air_date') and temporada['air_date']:
if 'air_date' in temporada and temporada['air_date']:
date = temporada['air_date'].split('-')
item.infoLabels['aired'] = date[2] + "/" + date[1] + "/" + date[0]
if temporada.has_key('poster_path') and temporada['poster_path']:
if 'poster_path' in temporada and temporada['poster_path']:
item.infoLabels['poster_path'] = 'http://image.tmdb.org/t/p/original' + temporada['poster_path']
item.thumbnail = item.infoLabels['poster_path']
@@ -507,7 +507,7 @@ def find_and_set_infoLabels(item):
title = title.replace(year, "").strip()
item.infoLabels['year'] = year[1:-1]
if not item.infoLabels.get("tmdb_id"):
if not item.infoLabels.get("tmdb_id") or not item.infoLabels.get("tmdb_id")[0].isdigit():
if not item.infoLabels.get("imdb_id"):
otmdb_global = Tmdb(texto_buscado=title, tipo=tipo_busqueda, year=item.infoLabels['year'])
else:

View File

@@ -235,7 +235,7 @@ def save_movie(item):
return 0, 0, -1
def filter_list(episodelist, action=None, path=None):
if path: path = path.decode('utf8')
# if path: path = path.decode('utf8')
# import xbmc
# if xbmc.getCondVisibility('system.platform.windows') > 0: path = path.replace('smb:','').replace('/','\\')
channel_prefs = {}

View File

@@ -164,7 +164,8 @@ def update_title(item):
item.channel = new_item.channel #Restuaramos el nombre del canal, por si lo habíamos cambiado
if item.tmdb_stat == True:
if new_item.contentSerieName: #Si es serie...
if config.get_setting("filter_languages", item.channel) >= 0:
filter_languages = config.get_setting("filter_languages", item.channel)
if filter_languages and filter_languages >= 0:
item.title_from_channel = new_item.contentSerieName #Guardo el título incial para Filtertools
item.contentSerieName = new_item.contentSerieName #Guardo el título incial para Filtertools
else: