Module: check_mk
Branch: master
Commit: 1c239455cecbf0ed80ecada3c2c844a2e4053589
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=1c239455cecbf0…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Mon Mar 3 14:00:37 2014 +0100
RBN: locking also inhibits change of parameterfs
---
modules/notify.py | 4 ++++
web/htdocs/wato.py | 4 ++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/modules/notify.py b/modules/notify.py
index b4eeefd..482795f 100644
--- a/modules/notify.py
+++ b/modules/notify.py
@@ -864,6 +864,10 @@ def notify_rulebased(context, analyse=False):
for contact in contacts:
key = contact, plugin
if key in notifications:
+ locked, method = notifications[key]
+ if locked and "contact" in rule:
+ notify_log(" - cannot modify notification of %s via
%s: it is locked" % key)
+ continue
notify_log(" - modifying notification of %s via %s" %
key)
else:
notify_log(" - adding notification of %s via %s" %
key)
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 43846a9..8895efc 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -7632,13 +7632,13 @@ def vs_notification_rule(userid = None):
style = "dropdown",
elements = [
ListOfStrings(
- title = _("Call this plugin with the following
parameters"),
+ title = _("Call the script with the following
parameters"),
valuespec = TextUnicode(size = 24),
orientation = "horizontal",
),
FixedValue(
value = None,
- title = _("Cancel all previous notifications with the
plugin"),
+ title = _("Cancel all previous notifications with this
method"),
totext = "",
),
]