Module: check_mk
Branch: master
Commit: fa17b8bc5392358d336b9b3ef06c34276ee13258
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=fa17b8bc539235…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Mon Mar 21 12:10:18 2016 +0100
3315 FIX Builtin icon visibility now can be correctly reset
After changing an icon to {{Show in column}} you could never reset this back
without a restart of the site Apache. This has been fixed.
---
.werks/3315 | 11 +++++++++++
ChangeLog | 1 +
web/plugins/views/painters.py | 18 ++++++++++++------
3 files changed, 24 insertions(+), 6 deletions(-)
diff --git a/.werks/3315 b/.werks/3315
new file mode 100644
index 0000000..e5f86cc
--- /dev/null
+++ b/.werks/3315
@@ -0,0 +1,11 @@
+Title: Builtin icon visibility now can be correctly reset
+Level: 1
+Component: multisite
+Class: fix
+Compatible: compat
+State: unknown
+Version: 1.2.9i1
+Date: 1458558544
+
+After changing an icon to {{Show in column}} you could never reset this back
+without a restart of the site Apache. This has been fixed.
diff --git a/ChangeLog b/ChangeLog
index 2a8f293..c3ba176 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -120,6 +120,7 @@
* 3293 FIX: Fixed graphs in IE with enabled compatibility mode (for IE < 8)
* 3294 FIX: Fixed mixed languages when some users have localized GUI and some not...
* 3313 FIX: Set correct mime type when exporting CSV and other non-HTML formats
+ * 3315 FIX: Builtin icon visibility now can be correctly reset...
WATO:
* 3244 WATO BI Module: swap order of aggregation function and child node
selection...
diff --git a/web/plugins/views/painters.py b/web/plugins/views/painters.py
index 46c13af..1daba9a 100644
--- a/web/plugins/views/painters.py
+++ b/web/plugins/views/painters.py
@@ -234,17 +234,23 @@ load_web_plugins('icons', globals())
def get_multisite_icons():
icons = {}
- for icon_id, icon in multisite_icons_and_actions.items():
- icon.setdefault('toplevel', False)
- icon.setdefault('sort_index', 30)
+ for icon_id, icon_config in multisite_icons_and_actions.items():
+ icon = {
+ "toplevel" : False,
+ "sort_index" : 30,
+ }
+ icon.update(icon_config)
icons[icon_id] = icon
# multisite_icons has been deprecated, but to be compatible to old icon
# plugins transform them to the new structure. We use part of the paint
# function name as icon id.
- for icon in multisite_icons:
- icon.setdefault('toplevel', False)
- icon.setdefault('sort_index', 30)
+ for icon_config in multisite_icons:
+ icon = {
+ "toplevel" : False,
+ "sort_index" : 30,
+ }
+ icon.update(icon_config)
icon_id = icon['paint'].__name__.replace('paint_', '')
icons[icon_id] = icon