Module: check_mk
Branch: master
Commit: 2715871eefef20457562b1f01827da11ce33c3a8
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=2715871eefef20…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Sep 4 16:57:11 2018 +0200
Fixed snapin dashlet rendering after GUI refactoring several weeks ago
CMK-887
Change-Id: I30dd65a06b35e273110f396653ab9cb0c8f5a10a
---
cmk/gui/plugins/dashboard/dashlets.py | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/cmk/gui/plugins/dashboard/dashlets.py
b/cmk/gui/plugins/dashboard/dashlets.py
index 8eef734..c9c177b 100644
--- a/cmk/gui/plugins/dashboard/dashlets.py
+++ b/cmk/gui/plugins/dashboard/dashlets.py
@@ -814,6 +814,7 @@ def dashlet_snapin(nr, dashlet):
snapin = sidebar.snapin_registry.get(dashlet['snapin'])
if not snapin:
raise MKUserError(None, _('The configured snapin does not exist.'))
+ snapin_instance = snapin()
dashlet_type = dashlet_types[dashlet['type']]
@@ -855,8 +856,8 @@ def dashlet_snapin(nr, dashlet):
html.open_div(id_="side_content")
html.open_div(id_="snapin_container_%s" % dashlet['snapin'],
class_="snapin")
html.open_div(id_="snapin_%s" % dashlet['snapin'],
class_="content")
- sidebar.render_snapin_styles(snapin)
- snapin.show()
+ sidebar.render_snapin_styles(snapin_instance)
+ snapin_instance.show()
html.close_div()
html.close_div()
html.close_div()