Module: check_mk
Branch: master
Commit: f558ed18cb05c028a14e28793774a5a5e4a14818
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f558ed18cb05c0…
Author: Sebastian Herbord <sh(a)mathias-kettner.de>
Date: Tue Mar 8 10:35:06 2016 +0100
3090 FIX fixed perf-o-meter link leading to old graph page even when new graphs are being
used
---
.werks/3090 | 10 ++++++++++
ChangeLog | 1 +
web/plugins/views/perfometer.py | 8 ++++++--
3 files changed, 17 insertions(+), 2 deletions(-)
diff --git a/.werks/3090 b/.werks/3090
new file mode 100644
index 0000000..39d46ae
--- /dev/null
+++ b/.werks/3090
@@ -0,0 +1,10 @@
+Title: fixed perf-o-meter link leading to old graph page even when new graphs are being
used
+Level: 1
+Component: multisite
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.9i1
+Date: 1457429645
+
+
diff --git a/ChangeLog b/ChangeLog
index eec95b0..a763e0a 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -78,6 +78,7 @@
* 3230 FIX: Slightly improved popup menu positioning...
* 3264 FIX: Fix display of values in graphs that are < 1.0
* 3273 FIX: Dashboard: The dashboard is now preserving edit/view state during page
reloads
+ * 3090 FIX: fixed perf-o-meter link leading to old graph page even when new graphs
are being used
WATO:
* 3244 WATO BI Module: swap order of aggregation function and child node
selection...
diff --git a/web/plugins/views/perfometer.py b/web/plugins/views/perfometer.py
index 4d01cb9..7e1390a 100644
--- a/web/plugins/views/perfometer.py
+++ b/web/plugins/views/perfometer.py
@@ -168,8 +168,12 @@ def paint_perfometer(row):
# pnpgraph_present: -1 means unknown (path not configured), 0: no, 1: yes
if 'X' in html.display_options and \
- row["service_pnpgraph_present"] != 0:
- return "perfometer" + stale_css, ('<a
href="%s">%s</a>' % (pnp_url(row, "service"), content))
+ row["service_pnpgraph_present"] != 0:
+ if metrics.cmk_graphs_possible():
+ url = new_graphing_url(row, "service")
+ else:
+ url = pnp_url(row, "service")
+ return "perfometer" + stale_css, ('<a
href="%s">%s</a>' % (url, content))
else:
return "perfometer" + stale_css, content