mirror of
https://github.com/Tautulli/Tautulli.git
synced 2025-07-31 03:50:11 -07:00
Create an option in settings to change home statistics length
This commit is contained in:
parent
a0bd94397c
commit
3fc2f43b79
4 changed files with 19 additions and 4 deletions
|
@ -71,6 +71,7 @@ _CONFIG_DEFINITIONS = {
|
|||
'GROWL_ON_PLAY': (int, 'Growl', 0),
|
||||
'GROWL_ON_STOP': (int, 'Growl', 0),
|
||||
'GROWL_ON_WATCHED': (int, 'Growl', 0),
|
||||
'HOME_STATS_LENGTH': (int, 'General', 30),
|
||||
'HTTPS_CERT': (str, 'General', ''),
|
||||
'HTTPS_KEY': (str, 'General', ''),
|
||||
'HTTP_HOST': (str, 'General', '0.0.0.0'),
|
||||
|
|
|
@ -64,7 +64,10 @@ class WebInterface(object):
|
|||
|
||||
@cherrypy.expose
|
||||
def home(self):
|
||||
return serve_template(templatename="index.html", title="Home")
|
||||
config = {
|
||||
"home_stats_length": plexpy.CONFIG.HOME_STATS_LENGTH
|
||||
}
|
||||
return serve_template(templatename="index.html", title="Home", config=config)
|
||||
|
||||
@cherrypy.expose
|
||||
def welcome(self, **kwargs):
|
||||
|
@ -434,7 +437,8 @@ class WebInterface(object):
|
|||
"notify_on_stop_subject_text": plexpy.CONFIG.NOTIFY_ON_STOP_SUBJECT_TEXT,
|
||||
"notify_on_stop_body_text": plexpy.CONFIG.NOTIFY_ON_STOP_BODY_TEXT,
|
||||
"notify_on_watched_subject_text": plexpy.CONFIG.NOTIFY_ON_WATCHED_SUBJECT_TEXT,
|
||||
"notify_on_watched_body_text": plexpy.CONFIG.NOTIFY_ON_WATCHED_BODY_TEXT
|
||||
"notify_on_watched_body_text": plexpy.CONFIG.NOTIFY_ON_WATCHED_BODY_TEXT,
|
||||
"home_stats_length": plexpy.CONFIG.HOME_STATS_LENGTH
|
||||
}
|
||||
|
||||
return serve_template(templatename="settings.html", title="Settings", config=config)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue