Version 0.7.0
This commit is contained in:
1 parent
8850589944
commit
f99b3d99da
3 files changed
+22
-17
No files matched your search
@@ -1,7 +1,7 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
|
||||||
<addon id="plugin.video.movistarplus"
|
<addon id="plugin.video.movistarplus"
|
||||||
name="Movistar+"
|
name="Movistar+"
|
||||||
version="0.6.6"
|
version="0.7.0"
|
||||||
provider-name="Paco8">
|
provider-name="Paco8">
|
||||||
<requires>
|
<requires>
|
||||||
<!--- <import addon="xbmc.python" version="2.25.0"/> -->
|
<!--- <import addon="xbmc.python" version="2.25.0"/> -->
|
||||||
|
|||||||
+19
-14
@@ -155,9 +155,11 @@ class Movistar(object):
|
|||||||
self.entitlements['activePurchases'] = data['activePurchases']
|
self.entitlements['activePurchases'] = data['activePurchases']
|
||||||
self.entitlements['partners'] = data['partners']
|
self.entitlements['partners'] = data['partners']
|
||||||
self.entitlements['activePackages'] = data['activePackages']
|
self.entitlements['activePackages'] = data['activePackages']
|
||||||
self.entitlements['vodSubscription'] = data['vodSubscription'].split(',')
|
self.entitlements['vodSubscription'] = data['vodSubscription'].split(',') if data['linearSubscription'] else []
|
||||||
self.entitlements['linearSubscription'] = data['linearSubscription'].split(',') if data['linearSubscription'] else []
|
self.entitlements['linearSubscription'] = data['linearSubscription'].split(',') if data['linearSubscription'] else []
|
||||||
self.entitlements['suscripcion'] = data['suscripcion']
|
self.entitlements['suscripcion'] = data['suscripcion']
|
||||||
|
self.entitlements['tvRights'] = data['tvRights']
|
||||||
|
self.entitlements['distilledTvRights'] = data['distilledTvRights']
|
||||||
#print_json(self.entitlements)
|
#print_json(self.entitlements)
|
||||||
self.logged = True
|
self.logged = True
|
||||||
|
|
||||||
@@ -517,13 +519,17 @@ class Movistar(object):
|
|||||||
for e in self.entitlements['activePurchases']:
|
for e in self.entitlements['activePurchases']:
|
||||||
if e['name'] in products:
|
if e['name'] in products:
|
||||||
return True
|
return True
|
||||||
|
for e in self.entitlements['tvRights']:
|
||||||
|
if e in products:
|
||||||
|
return True
|
||||||
return False
|
return False
|
||||||
|
|
||||||
def is_subscribed_vod(self, products):
|
def is_subscribed_vod(self, products):
|
||||||
for p in products:
|
#for p in products:
|
||||||
if p['Nombre'] in self.entitlements['vodSubscription']:
|
# if p['Nombre'] in self.entitlements['vodSubscription']:
|
||||||
return True
|
# return True
|
||||||
return False
|
#return False
|
||||||
|
return self.is_subscribed_channel(products)
|
||||||
|
|
||||||
def get_channels(self, add_epg_info = False):
|
def get_channels(self, add_epg_info = False):
|
||||||
if add_epg_info:
|
if add_epg_info:
|
||||||
@@ -556,7 +562,7 @@ class Movistar(object):
|
|||||||
t['url'] = c['PuntoReproduccion']
|
t['url'] = c['PuntoReproduccion']
|
||||||
t['art']['icon'] = t['art']['thumb'] = t['art']['poster'] = c['Logo']
|
t['art']['icon'] = t['art']['thumb'] = t['art']['poster'] = c['Logo']
|
||||||
t['session_request'] = '{"contentID":"'+ t['id'] +'", "streamType":"CHN"}'
|
t['session_request'] = '{"contentID":"'+ t['id'] +'", "streamType":"CHN"}'
|
||||||
t['subscribed'] = self.is_subscribed_channel(c['Productos'])
|
t['subscribed'] = self.is_subscribed_channel(c.get('tvProducts', []))
|
||||||
t['info']['playcount'] = 1 # Set as watched
|
t['info']['playcount'] = 1 # Set as watched
|
||||||
# epg
|
# epg
|
||||||
if add_epg_info:
|
if add_epg_info:
|
||||||
@@ -613,8 +619,7 @@ class Movistar(object):
|
|||||||
ACCOUNTNUMBER=self.account['id'],
|
ACCOUNTNUMBER=self.account['id'],
|
||||||
profile=self.account['platform'],
|
profile=self.account['platform'],
|
||||||
texto=search_term,
|
texto=search_term,
|
||||||
linearSubscription=','.join(self.entitlements['linearSubscription']),
|
distilledTvRights=','.join(self.entitlements['distilledTvRights']),
|
||||||
vodSubscription=','.join(self.entitlements['vodSubscription']),
|
|
||||||
mdrm='true', demarcation=self.account['demarcation'])
|
mdrm='true', demarcation=self.account['demarcation'])
|
||||||
return url
|
return url
|
||||||
|
|
||||||
@@ -633,7 +638,7 @@ class Movistar(object):
|
|||||||
ed = data['DatosEditoriales']
|
ed = data['DatosEditoriales']
|
||||||
t['id'] = ed['Id']
|
t['id'] = ed['Id']
|
||||||
t['info']['title'] = ed['Titulo']
|
t['info']['title'] = ed['Titulo']
|
||||||
t['art']['poster'] = ed['Imagen'].replace('ywcatalogov', 'dispficha')
|
t['art']['poster'] = ed.get('Imagen', '').replace('ywcatalogov', 'dispficha')
|
||||||
t['art']['thumb'] = t['art']['poster']
|
t['art']['thumb'] = t['art']['poster']
|
||||||
t['info']['genre'] = ed['GeneroComAntena']
|
t['info']['genre'] = ed['GeneroComAntena']
|
||||||
if ed.get('TipoComercial') == 'Impulsivo': return None # Alquiler
|
if ed.get('TipoComercial') == 'Impulsivo': return None # Alquiler
|
||||||
@@ -646,7 +651,7 @@ class Movistar(object):
|
|||||||
t['session_request'] = ''
|
t['session_request'] = ''
|
||||||
if len(data['VodItems']) > 0:
|
if len(data['VodItems']) > 0:
|
||||||
video = data['VodItems'][0]
|
video = data['VodItems'][0]
|
||||||
t['subscribed'] = self.is_subscribed_vod(video['Productos'])
|
t['subscribed'] = self.is_subscribed_vod(video.get('tvProducts', []))
|
||||||
if not 'UrlVideo' in video: return None
|
if not 'UrlVideo' in video: return None
|
||||||
t['url'] = video['UrlVideo']
|
t['url'] = video['UrlVideo']
|
||||||
if video['AssetType'] == 'VOD':
|
if video['AssetType'] == 'VOD':
|
||||||
@@ -671,11 +676,11 @@ class Movistar(object):
|
|||||||
if ed['TipoContenido'] == 'Serie':
|
if ed['TipoContenido'] == 'Serie':
|
||||||
t['type'] = 'series'
|
t['type'] = 'series'
|
||||||
t['info']['mediatype'] = 'tvshow'
|
t['info']['mediatype'] = 'tvshow'
|
||||||
t['subscribed'] = self.is_subscribed_vod(data['Productos'])
|
t['subscribed'] = self.is_subscribed_vod(data.get('tvProducts', []))
|
||||||
if ed['TipoContenido'] == 'Temporada':
|
if ed['TipoContenido'] == 'Temporada':
|
||||||
t['type'] = 'season'
|
t['type'] = 'season'
|
||||||
t['info']['mediatype'] = 'season'
|
t['info']['mediatype'] = 'season'
|
||||||
t['subscribed'] = self.is_subscribed_vod(data['Productos'])
|
t['subscribed'] = self.is_subscribed_vod(data.get('tvProducts', []))
|
||||||
|
|
||||||
return t
|
return t
|
||||||
|
|
||||||
@@ -777,7 +782,7 @@ class Movistar(object):
|
|||||||
t['info']['plot'] = data['Descripcion']
|
t['info']['plot'] = data['Descripcion']
|
||||||
t['info']['season'] = c
|
t['info']['season'] = c
|
||||||
t['art']['poster'] = t['art']['thumb'] = data['Imagen']
|
t['art']['poster'] = t['art']['thumb'] = data['Imagen']
|
||||||
t['subscribed'] = self.is_subscribed_vod(data['Productos'])
|
t['subscribed'] = self.is_subscribed_vod(data.get('tvProducts', []))
|
||||||
c += 1
|
c += 1
|
||||||
res.append(t)
|
res.append(t)
|
||||||
|
|
||||||
@@ -812,7 +817,7 @@ class Movistar(object):
|
|||||||
t['session_request'] = ''
|
t['session_request'] = ''
|
||||||
if len(d['VodItems']) > 0:
|
if len(d['VodItems']) > 0:
|
||||||
video = d['VodItems'][0]
|
video = d['VodItems'][0]
|
||||||
t['subscribed'] = self.is_subscribed_vod(video['Productos'])
|
t['subscribed'] = self.is_subscribed_vod(video.get('tvProducts', []))
|
||||||
t['url'] = video['UrlVideo']
|
t['url'] = video['UrlVideo']
|
||||||
if video['AssetType'] == 'VOD':
|
if video['AssetType'] == 'VOD':
|
||||||
t['session_request'] = '{"contentID":' + str(t['id']) + ',"drmMediaID":"' + video['CasId'] +'", "streamType":"AST"}'
|
t['session_request'] = '{"contentID":' + str(t['id']) + ',"drmMediaID":"' + video['CasId'] +'", "streamType":"AST"}'
|
||||||
|
|||||||
@@ -6,8 +6,8 @@
|
|||||||
<setting id="use_ttml2ssa" type="bool" label="$ADDON[script.module.ttml2ssa 32202]" default="false"/>
|
<setting id="use_ttml2ssa" type="bool" label="$ADDON[script.module.ttml2ssa 32202]" default="false"/>
|
||||||
<setting id="ssa_settings" type="action" label="$ADDON[script.module.ttml2ssa 32201]" option="close" action="Addon.OpenSettings(script.module.ttml2ssa)" enable="eq(-1,true)" subsetting="true"/>
|
<setting id="ssa_settings" type="action" label="$ADDON[script.module.ttml2ssa 32201]" option="close" action="Addon.OpenSettings(script.module.ttml2ssa)" enable="eq(-1,true)" subsetting="true"/>
|
||||||
<setting label="30019" type="action" id="is_settings" action="Addon.OpenSettings(inputstream.adaptive)" enable="System.HasAddon(inputstream.adaptive)" option="close"/>
|
<setting label="30019" type="action" id="is_settings" action="Addon.OpenSettings(inputstream.adaptive)" enable="System.HasAddon(inputstream.adaptive)" option="close"/>
|
||||||
<setting id="reuse_devices" type="bool" label="30023" default="false" visible="false"/>
|
<setting id="reuse_devices" type="bool" label="30023" default="false" visible="true"/>
|
||||||
<setting id="open_session" type="bool" label="30022" default="true" visible="false"/>
|
<setting id="open_session" type="bool" label="30022" default="true" visible="true"/>
|
||||||
<setting type="sep"/>
|
<setting type="sep"/>
|
||||||
<setting id="profile_id" type="labelenum" label="Profile ID" values="Auto|OTT|NODTH"/>
|
<setting id="profile_id" type="labelenum" label="Profile ID" values="Auto|OTT|NODTH"/>
|
||||||
</category>
|
</category>
|
||||||
|
|||||||
Reference in new issue
Block a user