Module: check_mk
Branch: master
Commit: f7c1e29d448fe9d0c0465b27f8fc4bbc1a1fea6f
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f7c1e29d448fe9…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Jun 17 14:52:22 2015 +0200
#2353 FIX Fix showing options for availability in BI mode, where above header
---
.werks/2353 | 10 ++++++++++
ChangeLog | 1 +
web/plugins/views/availability.py | 8 +++-----
3 files changed, 14 insertions(+), 5 deletions(-)
diff --git a/.werks/2353 b/.werks/2353
new file mode 100644
index 0000000..86dfa1b
--- /dev/null
+++ b/.werks/2353
@@ -0,0 +1,10 @@
+Title: Fix showing options for availability in BI mode, where above header
+Level: 1
+Component: multisite
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.7i2
+Date: 1434545517
+
+
diff --git a/ChangeLog b/ChangeLog
index 517a535..b6854c6 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -44,6 +44,7 @@
* 2337 FIX: Fixed problem with long hanging pnp graph rendering calls
* 2338 FIX: Logging internal GUI exceptions to web.log instead of apache
error_log...
* 2340 FIX: Email validation: Top level domains can now have a maximum length of 24
characters
+ * 2353 FIX: Fix showing options for availability in BI mode, where above header
WATO:
* 1254 The target address for crash reports can now be configured in wato global
settings
diff --git a/web/plugins/views/availability.py b/web/plugins/views/availability.py
index 1904a14..7220aaa 100644
--- a/web/plugins/views/availability.py
+++ b/web/plugins/views/availability.py
@@ -469,11 +469,8 @@ def render_timeline_bar(timeline_layout, style):
def render_bi_availability(title, aggr_rows):
av_mode = html.var("av_mode", "availability")
- html.plug()
- avoptions = render_availability_options()
+ avoptions = get_availability_options_from_url()
time_range, range_title = avoptions["range"]
- avoptions_html = html.drain()
- html.unplug()
if av_mode == "timeline":
title = _("Timeline of ") + title
@@ -481,7 +478,6 @@ def render_bi_availability(title, aggr_rows):
title = _("Availability of ") + title
if html.output_format != "csv_export":
- html.write(avoptions_html)
html.body_start(title,
stylesheets=["pages","views","status", "bi"],
javascripts=['bi'])
html.top_heading(title)
html.begin_context_buttons()
@@ -502,6 +498,8 @@ def render_bi_availability(title, aggr_rows):
html.context_button(_("Timeline"), timeline_url,
"timeline")
html.end_context_buttons()
+ avoptions = render_availability_options()
+
if not html.has_user_errors():
spans = []