[polpoTV] json fix + scraped thumbnail
This commit is contained in:
@@ -1,7 +1,7 @@
|
|||||||
{
|
{
|
||||||
"id": "polpotv",
|
"id": "polpotv",
|
||||||
"name": "PolpoTV",
|
"name": "PolpoTV",
|
||||||
"language": ["it"],
|
"language": ["ita"],
|
||||||
"active": true,
|
"active": true,
|
||||||
"adult": false,
|
"adult": false,
|
||||||
"thumbnail": "https://polpo.tv/build/assets/apple-touch-icon-152x152.png",
|
"thumbnail": "https://polpo.tv/build/assets/apple-touch-icon-152x152.png",
|
||||||
|
|||||||
+22
-13
@@ -95,6 +95,7 @@ def findvideos(item):
|
|||||||
return itemlist
|
return itemlist
|
||||||
|
|
||||||
def get_itemlist_movie(movie,item):
|
def get_itemlist_movie(movie,item):
|
||||||
|
logger.info("kod.polpotv get_itemlist_movie")
|
||||||
itemlist=[]
|
itemlist=[]
|
||||||
try:
|
try:
|
||||||
if movie['originalLanguage']['id']=='it':
|
if movie['originalLanguage']['id']=='it':
|
||||||
@@ -102,24 +103,32 @@ def get_itemlist_movie(movie,item):
|
|||||||
else:
|
else:
|
||||||
scrapedtitle=movie['translations'][1]['name']
|
scrapedtitle=movie['translations'][1]['name']
|
||||||
if scrapedtitle=='':
|
if scrapedtitle=='':
|
||||||
scrapedtitle=movie['originalTitle']
|
scrapedtitle=movie['originalTitle']
|
||||||
except:
|
except:
|
||||||
scrapedtitle=movie['originalTitle']
|
scrapedtitle=movie['originalTitle']
|
||||||
try:
|
try:
|
||||||
scrapedplot=movie['translations'][1]['overview']
|
scrapedplot=movie['translations'][1]['overview']
|
||||||
except:
|
except:
|
||||||
scrapedplot = ""
|
scrapedplot = ""
|
||||||
scrapedthumbnail = ""
|
try:
|
||||||
|
scrapedthumbnail="http://"+movie['posterPath']
|
||||||
|
except:
|
||||||
|
scrapedthumbnail=""
|
||||||
|
try:
|
||||||
|
scrapedfanart="http://"+movie['backdropPath']
|
||||||
|
except:
|
||||||
|
scrapedfanart=""
|
||||||
itemlist.append(
|
itemlist.append(
|
||||||
Item(channel=item.channel,
|
Item(channel=item.channel,
|
||||||
action="findvideos",
|
action="findvideos",
|
||||||
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
|
title="[COLOR azure]" + scrapedtitle + "[/COLOR]",
|
||||||
fulltitle=scrapedtitle,
|
fulltitle=scrapedtitle,
|
||||||
show=scrapedtitle,
|
show=scrapedtitle,
|
||||||
plot=scrapedplot,
|
plot=scrapedplot,
|
||||||
thumbnail=scrapedthumbnail,
|
fanart=scrapedfanart,
|
||||||
contentType='movie',
|
thumbnail=scrapedthumbnail,
|
||||||
contentTitle=scrapedtitle,
|
contentType='movie',
|
||||||
url="%s%s/releases" %(host,movie['@id'] ),
|
contentTitle=scrapedtitle,
|
||||||
extra=item.extra))
|
url="%s%s/releases" %(host,movie['@id'] ),
|
||||||
|
extra=item.extra))
|
||||||
return itemlist
|
return itemlist
|
||||||
|
|||||||
Reference in New Issue
Block a user