Module: check_mk
Branch: master
Commit: f09991ba54e2cb715c386fb2aca33167525a9a87
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=f09991ba54e2cb…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Thu Oct 4 17:40:08 2012 +0200
WATO: WATO folder filter no longer available on single host views
Fixed: Wato filter no longer available when config.wato_enabled == False
---
ChangeLog | 2 ++
web/htdocs/views.py | 8 ++++----
2 files changed, 6 insertions(+), 4 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 124aa05..ff32f6c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -14,6 +14,8 @@
* FIX: Speed-o-meter: Fixed calculation of Check_MK passive check invervals
* Removed focus of "Full name" attribute on editing a contact
* Quicksearch: Convert search text to regex when accessing livestatus
+ * FIX: WATO Folder filter not available when WATO disabled
+ * WATO Folder Filter no longer available in single host views
BI:
* Added missing localizations
diff --git a/web/htdocs/views.py b/web/htdocs/views.py
index 92a73ca..7e7c505 100644
--- a/web/htdocs/views.py
+++ b/web/htdocs/views.py
@@ -1182,8 +1182,8 @@ def show_view(view, show_heading = False, show_buttons = True,
# add ubiquitary_filters that are possible for this datasource
for fn in ubiquitary_filters:
- # Disable 'filename' filter, if WATO is disabled
- if fn == "filename" and not config.wato_enabled:
+ # Disable 'wato_folder' filter, if WATO is disabled or there is a single
host view
+ if fn == "wato_folder" and (not config.wato_enabled or "host"
in view["hide_filters"]):
continue
filter = multisite_filters[fn]
if not filter.info or filter.info in datasource["infos"]:
@@ -1577,8 +1577,8 @@ def view_title(view):
title = view["title"] + " " + ", ".join(extra_titles)
for fn in ubiquitary_filters:
- # Disable 'filename' filter, if WATO is disabled
- if fn == "filename" and not config.wato_enabled:
+ # Disable 'wato_folder' filter, if WATO is disabled or there is a single
host view
+ if fn == "wato_folder" and (not config.wato_enabled or "host"
in view["hide_filters"]):
continue
filt = multisite_filters[fn]
heading = filt.heading_info(tablename)