mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-31 03:50:11 -07:00
Add server selection dropdown to settings
This commit is contained in:
parent
e1dca1509a
commit
2621da7d36
7 changed files with 305 additions and 228 deletions
|
@ -85,9 +85,9 @@ class HTTPHandler(object):
|
|||
if uri:
|
||||
request_urls = [urljoin(url, self.uri) for url in self.urls]
|
||||
|
||||
if no_token and headers:
|
||||
self.headers = headers
|
||||
elif headers:
|
||||
if no_token:
|
||||
self.headers.pop('X-Plex-Token', None)
|
||||
if headers:
|
||||
self.headers.update(headers)
|
||||
|
||||
responses = []
|
||||
|
|
|
@ -646,7 +646,8 @@ class PlexTV(object):
|
|||
'ip': helpers.get_xml_attr(c, 'address'),
|
||||
'port': helpers.get_xml_attr(c, 'port'),
|
||||
'local': helpers.get_xml_attr(c, 'local'),
|
||||
'value': helpers.get_xml_attr(c, 'address')
|
||||
'value': helpers.get_xml_attr(c, 'address'),
|
||||
'is_cloud': is_cloud
|
||||
}
|
||||
clean_servers.append(server)
|
||||
|
||||
|
|
|
@ -117,7 +117,7 @@ class WebInterface(object):
|
|||
@cherrypy.tools.json_out()
|
||||
@requireAuth(member_of("admin"))
|
||||
@addtoapi("get_server_list")
|
||||
def discover(self, token=None, include_cloud=True, all_servers=False, **kwargs):
|
||||
def discover(self, token=None, include_cloud=True, all_servers=True, **kwargs):
|
||||
""" Get all your servers that are published to Plex.tv.
|
||||
|
||||
```
|
||||
|
@ -148,7 +148,7 @@ class WebInterface(object):
|
|||
plexpy.CONFIG.write()
|
||||
|
||||
include_cloud = not (include_cloud == 'false')
|
||||
all_servers = (all_servers == 'true')
|
||||
all_servers = not (all_servers == 'false')
|
||||
|
||||
plex_tv = plextv.PlexTV()
|
||||
servers_list = plex_tv.discover(include_cloud=include_cloud,
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue