Module: check_mk
Branch: master
Commit: a6901cf1ce7b37f04bb8b9ae72c6bf8e130a2a35
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=a6901cf1ce7b37…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Tue Apr 28 14:04:04 2015 +0200
Moveing and deleting graphs in a collection
---
web/htdocs/pagetypes.py | 19 +++++++++++++++++--
1 file changed, 17 insertions(+), 2 deletions(-)
diff --git a/web/htdocs/pagetypes.py b/web/htdocs/pagetypes.py
index fe06056..3a30c68 100644
--- a/web/htdocs/pagetypes.py
+++ b/web/htdocs/pagetypes.py
@@ -204,6 +204,12 @@ class PageRenderer:
# | Examples: views, dashboards, graphs collections |
# '----------------------------------------------------------------------'
class Overridable:
+ def page_header(self):
+ header = self.type_title() + " - " + self.title()
+ if not self.is_mine():
+ header += " (%s)" % self.owner()
+ return header
+
# Checks wether a page is publicly visible. This does not only need a flag
# in the page itself, but also the permission from its owner to publish it.
def is_public(self):
@@ -351,6 +357,8 @@ class Overridable:
foreign = None
for page in self.instances():
+ if page.name() != name:
+ continue
if page.is_mine() and config.may("general.edit_" + self.type_name()):
mine = page
@@ -613,6 +621,11 @@ class Container(Overridable):
def add_element(self, element):
self._.setdefault("elements", []).append(element)
+ def move_element(self, nr, whither):
+ el = self._["elements"][nr]
+ del self._["elements"][nr]
+ self._["elements"][whither:whither] = [ el ]
+
def is_empty(self):
return not self.elements()
@@ -659,11 +672,13 @@ class Container(Overridable):
if not page.is_mine():
page = page.clone()
if isinstance(page, PageRenderer) and not page.is_hidden():
- need_sidebar_reload
+ need_sidebar_reload = True
page.add_element(create_info) # can be overridden
self.save_user_instances()
- return page, need_sidebar_reload
+ return None, need_sidebar_reload
+ # With a redirect directly to the page afterwards do it like this:
+ # return page, need_sidebar_reload
#.
Module: check_mk
Branch: master
Commit: 4d6ea87d7fc0fb53b5a205ed551d52fd73f45a8c
URL: http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=4d6ea87d7fc0fb…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Wed Apr 29 13:48:03 2015 +0200
#2248 The Event Console can now translate incoming SNMP traps
The Event Console can be configured to receive SNMP traps. In the past it
only extracted all raw OIDs and values from the incoming trap and putting
them together in the event message as they come in.
Now it is possible to use SNMP MIB files to let the Event Console translate
the OIDs, values and units contained in the traps.
This feature is disabled by default. You need to enable the Event Console
and the SNMP trap handling by using <tt>omd config</tt> in OMD environments.
Then you need to enable the trap translation in <i>Event Console > Settings</i>
by setting <i>Translate SNMP traps</i> to <i>on</i>. Finally you need to
activate the pending EC-Change.
Now all available MIBs will be used to translate the incoming traps.
You can now upload custom MIB files using the MIB management page at
<i>Event Console > SNMP MIBs</i> which will be used for translation after
reloading the Event Console.
---
.werks/2248 | 27 +++++++++++++++++++++++++++
ChangeLog | 1 +
2 files changed, 28 insertions(+)
diff --git a/.werks/2248 b/.werks/2248
new file mode 100644
index 0000000..85c6909
--- /dev/null
+++ b/.werks/2248
@@ -0,0 +1,27 @@
+Title: The Event Console can now translate incoming SNMP traps
+Level: 2
+Component: ec
+Compatible: compat
+Version: 1.2.7i1
+Date: 1430307780
+Class: feature
+
+The Event Console can be configured to receive SNMP traps. In the past it
+only extracted all raw OIDs and values from the incoming trap and putting
+them together in the event message as they come in.
+
+Now it is possible to use SNMP MIB files to let the Event Console translate
+the OIDs, values and units contained in the traps.
+
+This feature is disabled by default. You need to enable the Event Console
+and the SNMP trap handling by using <tt>omd config</tt> in OMD environments.
+
+Then you need to enable the trap translation in <i>Event Console > Settings</i>
+by setting <i>Translate SNMP traps</i> to <i>on</i>. Finally you need to
+activate the pending EC-Change.
+
+Now all available MIBs will be used to translate the incoming traps.
+
+You can now upload custom MIB files using the MIB management page at
+<i>Event Console > SNMP MIBs</i> which will be used for translation after
+reloading the Event Console.
diff --git a/ChangeLog b/ChangeLog
index bcdb9e5..8e94594 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -515,6 +515,7 @@
* 2099 Allow replication of Event Console rule and settings...
* 2107 mkeventd: can now handle syslog format of Sophos firewalls
* 2223 Allow cancelling actions to be omitted of the cancelled event is not (yet) open...
+ * 2248 The Event Console can now translate incoming SNMP traps...
* 1839 FIX: Fix exception when notifying EC alert into monitoring for traps (because PID is missing)
* 1813 FIX: Fixed bug in event console rule editor when no contact groups configured
* 1974 FIX: Event console views were randomly ignoring host filters...