Module: check_mk
Branch: master
Commit: 0850b4767b80137dfa63c83d67b04de43451f211
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=0850b4767b8013…
Author: Andreas Boesl <ab(a)mathias-kettner.de>
Date: Thu Nov 14 16:00:16 2013 +0100
FIX fixed bug in multisite command execution
The command STAR (set/unset favorites) got called on every action command
---
.werks/36 | 8 ++++++++
ChangeLog | 1 +
web/plugins/views/commands.py | 13 +++++++------
3 files changed, 16 insertions(+), 6 deletions(-)
diff --git a/.werks/36 b/.werks/36
new file mode 100644
index 0000000..9400de2
--- /dev/null
+++ b/.werks/36
@@ -0,0 +1,8 @@
+Title: fixed bug in multisite command execution
+Level: 2
+Component: ec
+Version: 1.2.3i7
+Date: 1384441145
+Class: fix
+
+The command STAR (set/unset favorites) got called on every action command
diff --git a/ChangeLog b/ChangeLog
index 96b7217..1a0966c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -56,6 +56,7 @@
Event Console:
* 0026 FIX: snmpd_mkevent.py: fixed crash on startup
+ * 0036 FIX: fixed bug in multisite command execution...
Livestatus:
* 0067 livedump: new option to mark the mode at the beginning of the dump and
documentation fixes...
diff --git a/web/plugins/views/commands.py b/web/plugins/views/commands.py
index 9a80f28..77a0595 100644
--- a/web/plugins/views/commands.py
+++ b/web/plugins/views/commands.py
@@ -522,12 +522,13 @@ def save_stars(stars):
def command_star(cmdtag, spec, row):
- star = html.var("_star") and 1 or 0
- if star:
- title = _("<b>add to you favorites</b>")
- else:
- title = _("<b>remove from your favorites</b>")
- return "STAR;%d;%s" % (star, spec), title
+ if html.var("_star") or html.var("_unstar"):
+ star = html.var("_star") and 1 or 0
+ if star:
+ title = _("<b>add to you favorites</b>")
+ else:
+ title = _("<b>remove from your favorites</b>")
+ return "STAR;%d;%s" % (star, spec), title
def command_executor_star(command, site):