Thumb per Download e vai alla serie
This commit is contained in:
@@ -121,22 +121,23 @@ def findvideos(item):
|
||||
data = re.sub(r'>\s+<', '> <', data)
|
||||
url_video = scrapertoolsV2.find_single_match(data, r'<div class="item"> <a data-id="[^"]+" data-href="([^"]+)" data-original="[^"]+"[^>]+> <div> <div class="title">Episodio \d+', -1)
|
||||
url_serie = scrapertoolsV2.find_single_match(data, r'<link rel="canonical" href="([^"]+)"\s?/>')
|
||||
goseries = support.typo("Vai alla Serie:" + item.contentSerieName, ' bold')
|
||||
goseries = support.typo(">> Vai alla Serie:" + item.contentSerieName, ' bold')
|
||||
series = support.typo(item.contentSerieName, ' bold color kod')
|
||||
|
||||
itemlist = support.server(item, data=url_video)
|
||||
|
||||
itemlist.append(
|
||||
Item(channel=item.channel,
|
||||
title=goseries + series,
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.show,
|
||||
contentType='tvshow',
|
||||
contentSerieName=item.contentSerieName,
|
||||
url=url_serie,
|
||||
action='episodios',
|
||||
contentTitle=item.contentSerieName,
|
||||
plot = goseries + series + "con tutte le puntate",
|
||||
))
|
||||
title=goseries + series,
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.show,
|
||||
contentType='tvshow',
|
||||
contentSerieName=item.contentSerieName,
|
||||
url=url_serie,
|
||||
action='episodios',
|
||||
contentTitle=item.contentSerieName,
|
||||
plot = goseries + series + "con tutte le puntate",
|
||||
thumbnail = support.thumb(thumb='channels_tvshow.png')
|
||||
))
|
||||
|
||||
return itemlist
|
||||
|
||||
@@ -269,7 +269,7 @@ def get_thumb(thumb_name, view="thumb_", auto=False):
|
||||
|
||||
else:
|
||||
icon_pack_name = config.get_setting('icon_set', default="default")
|
||||
media_path = os.path.join("https://raw.githubusercontent.com/kodiondemand/media/master/themes/", icon_pack_name)
|
||||
media_path = os.path.join("https://raw.githubusercontent.com/kodiondemand/media/master/themes", icon_pack_name)
|
||||
|
||||
if config.get_setting('enable_custom_theme') and config.get_setting('custom_theme') and os.path.isfile(config.get_setting('custom_theme') + view + thumb_name):
|
||||
media_path = config.get_setting('custom_theme')
|
||||
@@ -344,7 +344,7 @@ def auto_filter(auto_lang=False):
|
||||
# return lang, lang_list
|
||||
|
||||
|
||||
def thumb(itemlist=[], genre=False):
|
||||
def thumb(itemlist=[], genre=False, thumb=''):
|
||||
if itemlist:
|
||||
import re
|
||||
|
||||
@@ -428,5 +428,7 @@ def thumb(itemlist=[], genre=False):
|
||||
|
||||
item.title = re.sub(r'\s*\{[^\}]+\}','',item.title)
|
||||
return itemlist
|
||||
elif thumb:
|
||||
return get_thumb(thumb)
|
||||
else:
|
||||
return get_thumb('next.png')
|
||||
|
||||
@@ -781,32 +781,34 @@ def download(itemlist, item, typography='', function_level=1, function=''):
|
||||
if itemlist and item.contentChannel != 'videolibrary':
|
||||
itemlist.append(
|
||||
Item(channel='downloads',
|
||||
from_channel=item.channel,
|
||||
title=title,
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.fulltitle,
|
||||
contentType=item.contentType,
|
||||
contentSerieName=contentSerieName,
|
||||
url=item.url,
|
||||
action='save_download',
|
||||
from_action=from_action,
|
||||
contentTitle=contentTitle,
|
||||
path=item.path
|
||||
from_channel=item.channel,
|
||||
title=title,
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.fulltitle,
|
||||
contentType=item.contentType,
|
||||
contentSerieName=contentSerieName,
|
||||
url=item.url,
|
||||
action='save_download',
|
||||
from_action=from_action,
|
||||
contentTitle=contentTitle,
|
||||
path=item.path,
|
||||
thumbnail=thumb(thumb='downloads.png')
|
||||
))
|
||||
if from_action == 'episodios':
|
||||
itemlist.append(
|
||||
Item(channel='downloads',
|
||||
from_channel=item.channel,
|
||||
title=typo(config.get_localized_string(60357),typography),
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.fulltitle,
|
||||
contentType=item.contentType,
|
||||
contentSerieName=contentSerieName,
|
||||
url=item.url,
|
||||
action='save_download',
|
||||
from_action=from_action,
|
||||
contentTitle=contentTitle,
|
||||
download='season'
|
||||
from_channel=item.channel,
|
||||
title=typo(config.get_localized_string(60357),typography),
|
||||
fulltitle=item.fulltitle,
|
||||
show=item.fulltitle,
|
||||
contentType=item.contentType,
|
||||
contentSerieName=contentSerieName,
|
||||
url=item.url,
|
||||
action='save_download',
|
||||
from_action=from_action,
|
||||
contentTitle=contentTitle,
|
||||
download='season',
|
||||
thumbnail=thumb(thumb='downloads.png')
|
||||
))
|
||||
|
||||
return itemlist
|
||||
|
||||
Reference in New Issue
Block a user