diff --git a/plugin.video.alfa/channels/allcalidad.json b/plugin.video.alfa/channels/allcalidad.json index 5c35e0cf..1d553516 100755 --- a/plugin.video.alfa/channels/allcalidad.json +++ b/plugin.video.alfa/channels/allcalidad.json @@ -19,6 +19,14 @@ "enabled": true, "visible": true }, + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_global_search", "type": "bool", diff --git a/plugin.video.alfa/channels/allcalidad.py b/plugin.video.alfa/channels/allcalidad.py index 8a64360a..04d73f46 100755 --- a/plugin.video.alfa/channels/allcalidad.py +++ b/plugin.video.alfa/channels/allcalidad.py @@ -33,7 +33,7 @@ def newest(categoria): itemlist = [] item = Item() try: - if categoria == 'peliculas': + if categoria in ['peliculas','latino']: item.url = host elif categoria == 'infantiles': item.url = host + 'category/animacion/' diff --git a/plugin.video.alfa/channels/allpeliculas.json b/plugin.video.alfa/channels/allpeliculas.json index 2574c95b..5338fb45 100755 --- a/plugin.video.alfa/channels/allpeliculas.json +++ b/plugin.video.alfa/channels/allpeliculas.json @@ -20,6 +20,14 @@ "enabled": true, "visible": true }, + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_newest_peliculas", "type": "bool", @@ -50,4 +58,4 @@ ] } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/allpeliculas.py b/plugin.video.alfa/channels/allpeliculas.py index 06175ca6..591163c3 100644 --- a/plugin.video.alfa/channels/allpeliculas.py +++ b/plugin.video.alfa/channels/allpeliculas.py @@ -217,7 +217,7 @@ def newest(categoria): itemlist = [] item = Item() try: - if categoria == "peliculas": + if categoria in ['peliculas','latino']: item.url = host + "movies/newmovies?page=1" item.action = "lista" itemlist = lista(item) diff --git a/plugin.video.alfa/channels/cinefoxtv.json b/plugin.video.alfa/channels/cinefoxtv.json index dfa107be..54bb5891 100755 --- a/plugin.video.alfa/channels/cinefoxtv.json +++ b/plugin.video.alfa/channels/cinefoxtv.json @@ -18,6 +18,14 @@ "enabled": false, "visible": false }, + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_newest_peliculas", "type": "bool", @@ -35,4 +43,4 @@ "visible": true } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/cinefoxtv.py b/plugin.video.alfa/channels/cinefoxtv.py index 5a33d19a..ef97f240 100644 --- a/plugin.video.alfa/channels/cinefoxtv.py +++ b/plugin.video.alfa/channels/cinefoxtv.py @@ -193,7 +193,7 @@ def newest(categoria): item = Item() # categoria='peliculas' try: - if categoria == 'peliculas': + if categoria in ['peliculas','latino']: item.url = host + 'page/1.html' elif categoria == 'infantiles': item.url = host + 'peliculas-de-genero/infantil/1.html' diff --git a/plugin.video.alfa/channels/estadepelis.json b/plugin.video.alfa/channels/estadepelis.json index 0a9c7ec0..5c75dc13 100755 --- a/plugin.video.alfa/channels/estadepelis.json +++ b/plugin.video.alfa/channels/estadepelis.json @@ -31,6 +31,14 @@ "VOS" ] }, + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_newest_peliculas", "type": "bool", @@ -56,4 +64,4 @@ "visible": true } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/estadepelis.py b/plugin.video.alfa/channels/estadepelis.py index a592c8f3..1b4fc936 100755 --- a/plugin.video.alfa/channels/estadepelis.py +++ b/plugin.video.alfa/channels/estadepelis.py @@ -457,7 +457,7 @@ def newest(categoria): item = Item() # categoria='peliculas' try: - if categoria == 'peliculas': + if categoria in ['peliculas','latino']: item.url = host elif categoria == 'infantiles': item.url = host + 'search?q=animación' diff --git a/plugin.video.alfa/channels/miradetodo.json b/plugin.video.alfa/channels/miradetodo.json index 16a9821b..03bc898b 100755 --- a/plugin.video.alfa/channels/miradetodo.json +++ b/plugin.video.alfa/channels/miradetodo.json @@ -18,6 +18,14 @@ "enabled": true, "visible": true }, + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_newest_peliculas", "type": "bool", @@ -35,4 +43,4 @@ "visible": true } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/miradetodo.py b/plugin.video.alfa/channels/miradetodo.py index 35110b07..78243829 100755 --- a/plugin.video.alfa/channels/miradetodo.py +++ b/plugin.video.alfa/channels/miradetodo.py @@ -382,7 +382,7 @@ def newest(categoria): itemlist = [] item = Item() try: - if categoria == 'peliculas': + if categoria in ['peliculas','latino']: item.url = host + 'page/1/?s' elif categoria == 'infantiles': diff --git a/plugin.video.alfa/channels/ohlatino.json b/plugin.video.alfa/channels/ohlatino.json index 7d50a531..1e39fd1a 100644 --- a/plugin.video.alfa/channels/ohlatino.json +++ b/plugin.video.alfa/channels/ohlatino.json @@ -18,6 +18,14 @@ "enabled": false, "visible": false }, + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_newest_peliculas", "type": "bool", @@ -35,4 +43,4 @@ "visible": true } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/ohlatino.py b/plugin.video.alfa/channels/ohlatino.py index 0e2c41a1..11a08812 100644 --- a/plugin.video.alfa/channels/ohlatino.py +++ b/plugin.video.alfa/channels/ohlatino.py @@ -183,7 +183,7 @@ def newest(categoria): logger.info() item = Item() try: - if categoria == 'peliculas': + if categoria in ['peliculas','latino']: item.url = host + '/release/2017/' elif categoria == 'infantiles': diff --git a/plugin.video.alfa/channels/peliculasaudiolatino.json b/plugin.video.alfa/channels/peliculasaudiolatino.json index 52d788ce..134f5aef 100755 --- a/plugin.video.alfa/channels/peliculasaudiolatino.json +++ b/plugin.video.alfa/channels/peliculasaudiolatino.json @@ -10,13 +10,45 @@ "movie" ], "settings": [ + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_global_search", "type": "bool", "label": "Incluir en busqueda global", - "default": false, + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_peliculas", + "type": "bool", + "label": "Incluir en Novedades - Peliculas", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_infantiles", + "type": "bool", + "label": "Incluir en Novedades - Infantiles", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_terror", + "type": "bool", + "label": "Incluir en Novedades - terror", + "default": true, "enabled": true, "visible": true } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/peliculasaudiolatino.py b/plugin.video.alfa/channels/peliculasaudiolatino.py index 197cc18c..8ab94e70 100644 --- a/plugin.video.alfa/channels/peliculasaudiolatino.py +++ b/plugin.video.alfa/channels/peliculasaudiolatino.py @@ -31,6 +31,29 @@ def mainlist(item): return itemlist +def newest(categoria): + logger.info() + itemlist = [] + item = Item() + try: + if categoria in ['peliculas','latino']: + item.url = HOST + elif categoria == 'infantiles': + item.url = HOST + '/genero/animacion.html' + elif categoria == 'terror': + item.url = HOST + '/genero/terror.html' + itemlist = peliculas(item) + if "Pagina" in itemlist[-1].title: + itemlist.pop() + except: + import sys + for line in sys.exc_info(): + logger.error("{0}".format(line)) + return [] + + return itemlist + + def peliculas(item): logger.info() diff --git a/plugin.video.alfa/channels/peliculasmx.json b/plugin.video.alfa/channels/peliculasmx.json index 29e1167b..8a1ffeb3 100755 --- a/plugin.video.alfa/channels/peliculasmx.json +++ b/plugin.video.alfa/channels/peliculasmx.json @@ -10,13 +10,45 @@ "movie" ], "settings": [ + { + "id": "include_in_newest_latino", + "type": "bool", + "label": "Incluir en Novedades - Latino", + "default": true, + "enabled": true, + "visible": true + }, { "id": "include_in_global_search", "type": "bool", "label": "Incluir en busqueda global", - "default": false, + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_peliculas", + "type": "bool", + "label": "Incluir en Novedades - Peliculas", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_infantiles", + "type": "bool", + "label": "Incluir en Novedades - Infantiles", + "default": true, + "enabled": true, + "visible": true + }, + { + "id": "include_in_newest_terror", + "type": "bool", + "label": "Incluir en Novedades - terror", + "default": true, "enabled": true, "visible": true } ] -} \ No newline at end of file +} diff --git a/plugin.video.alfa/channels/peliculasmx.py b/plugin.video.alfa/channels/peliculasmx.py index 81ccd672..90e211ca 100644 --- a/plugin.video.alfa/channels/peliculasmx.py +++ b/plugin.video.alfa/channels/peliculasmx.py @@ -10,28 +10,47 @@ from core.item import Item from platformcode import logger - +host = "http://www.peliculasmx.net" def mainlist(item): logger.info() itemlist = [] itemlist.append( - Item(channel=item.channel, title="Últimas añadidas", action="peliculas", url="http://www.peliculasmx.net/")) + Item(channel=item.channel, title="Últimas añadidas", action="peliculas", url=host)) itemlist.append( - Item(channel=item.channel, title="Últimas por género", action="generos", url="http://www.peliculasmx.net/")) - itemlist.append(Item(channel=item.channel, title="Buscar...", action="search", url="http://www.peliculasmx.net/")) + Item(channel=item.channel, title="Últimas por género", action="generos", url=host)) + itemlist.append(Item(channel=item.channel, title="Buscar...", action="search", url=host)) + return itemlist + + +def newest(categoria): + logger.info() + itemlist = [] + item = Item() + try: + if categoria in ['peliculas','latino']: + item.url = host + elif categoria == 'infantiles': + item.url = host + '/category/animacion/' + elif categoria == 'terror': + item.url = host + '/category/terror/' + itemlist = peliculas(item) + if "Pagina" in itemlist[-1].title: + itemlist.pop() + except: + import sys + for line in sys.exc_info(): + logger.error("{0}".format(line)) + return [] + return itemlist def generos(item): logger.info() itemlist = [] - - # Descarga la página data = httptools.downloadpage(item.url).data - logger.debug(data) - #
  • Accion 246 patron = '