Module: check_mk
Branch: master
Commit: 7383a6c94e263f38096ea3b4ac07805bf61a6a01
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=7383a6c94e263f…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Fri Apr 17 16:49:43 2015 +0200
Disabled new graphing in mobile GUI
---
web/htdocs/htmllib.py | 3 +++
web/plugins/views/painters.py | 6 ++++--
2 files changed, 7 insertions(+), 2 deletions(-)
diff --git a/web/htdocs/htmllib.py b/web/htdocs/htmllib.py
index 0f5d08f..13d78de 100644
--- a/web/htdocs/htmllib.py
+++ b/web/htdocs/htmllib.py
@@ -128,6 +128,9 @@ class html:
BACKSPACE = 8
F1 = 112
+ def is_mobile(self):
+ return self.mobile
+
def get_user_agent(self):
return self.req.headers_in.get('User-Agent', '')
diff --git a/web/plugins/views/painters.py b/web/plugins/views/painters.py
index 95242ac..3c0282b 100644
--- a/web/plugins/views/painters.py
+++ b/web/plugins/views/painters.py
@@ -798,8 +798,10 @@ multisite_painters["svc_group_memberlist"] = {
}
def paint_graph(row):
- # Filter some clients which do not support our graphing, for example IE < 8
- try_time_graph = True
+ # Filter cases where our graphing is not possible:
+ # - mobile GUI
+ # - for example IE < 8
+ try_time_graph = not html.is_mobile()
user_agent = html.get_user_agent()
if 'MSIE' in user_agent: