summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLukas Metzger2020-06-10 15:05:46 +0200
committerLukas Metzger2020-06-10 15:05:46 +0200
commitcf6b307c1fbfa84800f5c003a87d48d2303c97b6 (patch)
tree03c8a1dd24d6d813f39c3311edf15fc9125b4528
parentChaged representation for machine locations to tables (diff)
downloadbwlp-statistics-cf6b307c1fbfa84800f5c003a87d48d2303c97b6.tar.gz
bwlp-statistics-cf6b307c1fbfa84800f5c003a87d48d2303c97b6.tar.xz
bwlp-statistics-cf6b307c1fbfa84800f5c003a87d48d2303c97b6.zip
Retain state after graphics update
-rw-r--r--pages/dozmod.py9
-rw-r--r--pages/total.py8
2 files changed, 12 insertions, 5 deletions
diff --git a/pages/dozmod.py b/pages/dozmod.py
index af97bab..37c108d 100644
--- a/pages/dozmod.py
+++ b/pages/dozmod.py
@@ -89,7 +89,8 @@ def make_graph_vms(days, rangeStart, rangeEnd, satellites):
name=title
))
figure.update_layout(
- title_text = 'VM Statistics'
+ title_text = 'VM Statistics',
+ uirevision=42
)
return figure
@@ -128,7 +129,8 @@ def make_graph_lectures(days, rangeStart, rangeEnd, satellites):
name=title
))
figure.update_layout(
- title_text = 'Lecture Statistics'
+ title_text = 'Lecture Statistics',
+ uirevision=42
)
return figure
@@ -176,7 +178,8 @@ def make_graph_users(days, rangeStart, rangeEnd, satellites):
figure.update_layout(
title_text = 'Users Statistics',
yaxis = dict(title='Users Total', side='left'),
- yaxis2 = dict(title = 'Users Organizations', side='right', overlaying='y')
+ yaxis2 = dict(title = 'Users Organizations', side='right', overlaying='y'),
+ uirevision=42
)
return figure
diff --git a/pages/total.py b/pages/total.py
index c22170a..bceb49b 100644
--- a/pages/total.py
+++ b/pages/total.py
@@ -104,7 +104,8 @@ def make_graph_times(days, rangeStart, rangeEnd, satellites):
))
figure.update_layout(
yaxis_ticksuffix=' h',
- title_text = 'Usage Times'
+ title_text = 'Usage Times',
+ uirevision=42
)
return figure
@@ -144,7 +145,8 @@ def make_graph_session_length(days, rangeStart, rangeEnd, satellites):
))
figure.update_layout(
yaxis_ticksuffix=' min',
- title_text = 'Median Session Length'
+ title_text = 'Median Session Length',
+ uirevision=42
)
return figure
@@ -190,6 +192,7 @@ def make_graph_sessions(days, rangeStart, rangeEnd, satellites):
figure.update_layout(
barmode='stack',
title_text = 'Sessions',
+ uirevision=42
)
return figure
@@ -229,6 +232,7 @@ def make_graph_users(days, rangeStart, rangeEnd, satellites):
figure.update_layout(
showlegend=True,
title_text = 'Unique Users',
+ uirevision=42
)
return figure