[polpoTV] json fix + scraped thumbnail

This commit is contained in:
Whiplash
2019-10-19 22:03:28 +02:00
parent aa19c3ec09
commit 4694b7cd33
2 changed files with 23 additions and 14 deletions
+1 -1
View File
@@ -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",
+10 -1
View File
@@ -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':
@@ -109,7 +110,14 @@ def get_itemlist_movie(movie,item):
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",
@@ -117,6 +125,7 @@ def get_itemlist_movie(movie,item):
fulltitle=scrapedtitle, fulltitle=scrapedtitle,
show=scrapedtitle, show=scrapedtitle,
plot=scrapedplot, plot=scrapedplot,
fanart=scrapedfanart,
thumbnail=scrapedthumbnail, thumbnail=scrapedthumbnail,
contentType='movie', contentType='movie',
contentTitle=scrapedtitle, contentTitle=scrapedtitle,