mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-14 17:22:56 -07:00
Save graph config to local storage instead of server
This commit is contained in:
parent
be0144bbe1
commit
0e0fb2e2b8
4 changed files with 128 additions and 165 deletions
|
@ -1849,24 +1849,6 @@ class WebInterface(object):
|
|||
|
||||
return serve_template(templatename="graphs.html", title="Graphs", config=config)
|
||||
|
||||
@cherrypy.expose
|
||||
@requireAuth(member_of("admin"))
|
||||
def set_graph_config(self, graph_type=None, graph_days=None, graph_months=None, graph_tab=None, **kwargs):
|
||||
if graph_type:
|
||||
plexpy.CONFIG.__setattr__('GRAPH_TYPE', graph_type)
|
||||
plexpy.CONFIG.write()
|
||||
if graph_days:
|
||||
plexpy.CONFIG.__setattr__('GRAPH_DAYS', graph_days)
|
||||
plexpy.CONFIG.write()
|
||||
if graph_months:
|
||||
plexpy.CONFIG.__setattr__('GRAPH_MONTHS', graph_months)
|
||||
plexpy.CONFIG.write()
|
||||
if graph_tab:
|
||||
plexpy.CONFIG.__setattr__('GRAPH_TAB', graph_tab)
|
||||
plexpy.CONFIG.write()
|
||||
|
||||
return "Updated graphs config values."
|
||||
|
||||
@cherrypy.expose
|
||||
@cherrypy.tools.json_out()
|
||||
@requireAuth()
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue