fix debriders
This commit is contained in:
@@ -136,6 +136,8 @@ def get_channel_json(channel_name):
|
||||
channel_path = filetools.join(config.get_runtime_path(), "specials", channel_name + ".json")
|
||||
if not os.path.isfile(channel_path):
|
||||
channel_path = filetools.join(config.get_runtime_path(), "servers", channel_name + ".json")
|
||||
if not os.path.isfile(channel_path):
|
||||
channel_path = filetools.join(config.get_runtime_path(), "servers", "debriders", channel_name + ".json")
|
||||
if filetools.isfile(channel_path):
|
||||
# logger.info("channel_data=" + channel_path)
|
||||
channel_json = jsontools.load(filetools.read(channel_path))
|
||||
|
||||
@@ -82,7 +82,7 @@ def now_on_misc(item):
|
||||
# Carica la pagina
|
||||
data = httptools.downloadpage(item.url).data
|
||||
#patron = r'spanTitleMovie">([A-Za-z À-ÖØ-öø-ÿ\-\']*)[a-z \n<>\/="_\-:0-9;A-Z.]*GenresMovie">([\-\'A-Za-z À-ÖØ-öø-ÿ\/]*)[a-z \n<>\/="_\-:0-9;A-Z.%]*src="([a-zA-Z:\/\.0-9?]*)[a-z \n<>\/="_\-:0-9;A-Z.%\-\']*Year">([A-Z 0-9a-z]*)'
|
||||
patron = r'table-cell[;" ]*alt="([a-zA-Z 0-9\+,\.]*)"[a-z \n<>\/="_\-:0-9;A-Z.?!\'\&, \(\)#]*backdrop" alt="([A-Za-z: ,0-9\.À-ÖØ-öø-ÿ\&\#\-\']*)"[ ]*src="([A-Za-z: ,0-9\.À-ÖØ-öø-ÿ\/?=\-\']*)'
|
||||
patron = r'table-cell[;" ]*alt="([^"]+)"[a-z \n<>\/="_\-:0-9;A-Z.?!\'\&, \(\)#]*backdrop" alt="([^"]+)"[ ]*src="([^"]+)'
|
||||
matches = re.compile(patron, re.DOTALL).findall(data)
|
||||
for scrapedchannel, scrapedtitle, scrapedthumbnail in matches:
|
||||
# for scrapedthumbnail, scrapedtitle, scrapedtv in matches:
|
||||
|
||||
+6
-5
@@ -85,8 +85,7 @@ def menu_channels(item):
|
||||
|
||||
|
||||
def channel_config(item):
|
||||
return platformtools.show_channel_settings(channelpath=filetools.join(config.get_runtime_path(), "channels",
|
||||
item.config))
|
||||
return platformtools.show_channel_settings(channelpath=filetools.join(config.get_runtime_path(), "channels", item.config))
|
||||
|
||||
|
||||
def autostart(item): # item necessario launcher.py linea 265
|
||||
@@ -145,7 +144,7 @@ def menu_servers(item):
|
||||
if server_parameters["has_settings"]:
|
||||
itemlist.append(
|
||||
Item(channel=CHANNELNAME, title = ". " + config.get_localized_string(60553) % server_parameters["name"],
|
||||
action="server_config", config=server, folder=False, thumbnail=""))
|
||||
action="server_debrid_config", config=server, folder=False, thumbnail=""))
|
||||
|
||||
itemlist.append(Item(channel=CHANNELNAME, title=config.get_localized_string(60554),
|
||||
action="", folder=False, text_bold = True, thumbnail=get_thumb("setting_0.png")))
|
||||
@@ -167,8 +166,10 @@ def menu_servers(item):
|
||||
|
||||
|
||||
def server_config(item):
|
||||
return platformtools.show_channel_settings(channelpath=filetools.join(config.get_runtime_path(), "servers",
|
||||
item.config))
|
||||
return platformtools.show_channel_settings(channelpath=filetools.join(config.get_runtime_path(), "servers", item.config))
|
||||
|
||||
def server_debrid_config(item):
|
||||
return platformtools.show_channel_settings(channelpath=filetools.join(config.get_runtime_path(), "servers", "debriders", item.config))
|
||||
|
||||
|
||||
def servers_blacklist(item):
|
||||
|
||||
Reference in New Issue
Block a user