Fix home stats Last Watched to use watched percent specified in settings
This commit is contained in:
@@ -69,6 +69,7 @@ class WebInterface(object):
|
||||
"home_stats_type": plexpy.CONFIG.HOME_STATS_TYPE,
|
||||
"home_stats_count": plexpy.CONFIG.HOME_STATS_COUNT,
|
||||
"pms_identifier": plexpy.CONFIG.PMS_IDENTIFIER,
|
||||
"notify_watched_percent": plexpy.CONFIG.NOTIFY_WATCHED_PERCENT
|
||||
}
|
||||
return serve_template(templatename="index.html", title="Home", config=config)
|
||||
|
||||
@@ -121,9 +122,12 @@ class WebInterface(object):
|
||||
return json.dumps(formats)
|
||||
|
||||
@cherrypy.expose
|
||||
def home_stats(self, time_range='30', stat_type='0', stat_count='5', **kwargs):
|
||||
def home_stats(self, time_range='30', stat_type='0', stat_count='5', notify_watched_percent='85', **kwargs):
|
||||
data_factory = datafactory.DataFactory()
|
||||
stats_data = data_factory.get_home_stats(time_range=time_range, stat_type=stat_type, stat_count=stat_count)
|
||||
stats_data = data_factory.get_home_stats(time_range=time_range,
|
||||
stat_type=stat_type,
|
||||
stat_count=stat_count,
|
||||
notify_watched_percent=notify_watched_percent)
|
||||
|
||||
return serve_template(templatename="home_stats.html", title="Stats", data=stats_data)
|
||||
|
||||
|
Reference in New Issue
Block a user