Module: check_mk
Branch: master
Commit: a94568a6ddae7fe5d2b8032ae7f57dc5e8790034
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=a94568a6ddae7f…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu May 28 14:35:25 2015 +0200
#2302 Availability: new option in "Labelling" for omitting legend for
availability levels
---
.werks/2302 | 9 +++++++++
ChangeLog | 1 +
web/htdocs/availability.py | 1 +
web/plugins/views/availability.py | 2 +-
4 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/.werks/2302 b/.werks/2302
new file mode 100644
index 0000000..e0c2736
--- /dev/null
+++ b/.werks/2302
@@ -0,0 +1,9 @@
+Title: Availability: new option in "Labelling" for omitting legend for
availability levels
+Level: 2
+Component: reporting
+Compatible: compat
+Version: 1.2.7i1
+Date: 1432816500
+Class: feature
+
+
diff --git a/ChangeLog b/ChangeLog
index 4c4938d..f3bf398 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -556,6 +556,7 @@
Reporting & Availability:
* 2301 Availability now allows just showing rows with outage times above certain
levels...
+ * 2302 Availability: new option in "Labelling" for omitting legend for
availability levels
* 1990 FIX: Fix two exceptions in PDF exports of host group views
* 2189 FIX: Allow changing graph number from 1 to "all" when editing PNP
graph in report...
* 2206 FIX: Add missing option "Show timeline of each object directly in
table" for reports...
diff --git a/web/htdocs/availability.py b/web/htdocs/availability.py
index 72b9ef0..ccb37e5 100644
--- a/web/htdocs/availability.py
+++ b/web/htdocs/availability.py
@@ -135,6 +135,7 @@ avoption_entries = [
( "use_display_name", _("Use alternative display name
for services")),
( "omit_buttons", _("Do not display icons for
history and timeline")),
( "display_timeline_legend", _("Display legend for
timeline")),
+ ( "omit_av_levels", _("Do not display legend for
availability levels")),
]
)
),
diff --git a/web/plugins/views/availability.py b/web/plugins/views/availability.py
index e21f776..1904a14 100644
--- a/web/plugins/views/availability.py
+++ b/web/plugins/views/availability.py
@@ -278,7 +278,7 @@ def render_availability_tables(availability_tables, what, avoptions):
# Legend for Availability levels
av_levels = avoptions["av_levels"]
- if av_levels:
+ if av_levels and not "omit_av_levels" in avoptions["labelling"]:
warn, crit = av_levels
html.write('<div class="avlegend levels">')
html.write('<h3>%s</h3>' % _("Availability
levels"))