Module: check_mk
Branch: master
Commit: bc6d2f5f472b5ba7d91f06b0241222f7d325c5c6
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=bc6d2f5f472b5b…
Author: Lars Michelsen <lm(a)mathias-kettner.de>
Date: Tue Jul 15 09:04:33 2014 +0200
FIX Fixed selection of hosts for bulk actions
---
.werks/1056 | 8 ++++++++
ChangeLog | 1 +
web/htdocs/weblib.py | 7 +++++--
3 files changed, 14 insertions(+), 2 deletions(-)
diff --git a/.werks/1056 b/.werks/1056
new file mode 100644
index 0000000..b701d88
--- /dev/null
+++ b/.werks/1056
@@ -0,0 +1,8 @@
+Title: Fixed selection of hosts for bulk actions
+Level: 1
+Component: wato
+Version: 1.2.5i5
+Date: 1405407835
+Class: fix
+
+
diff --git a/ChangeLog b/ChangeLog
index e7dc726..0ab6b7c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -64,6 +64,7 @@
* 0947 FIX: WATO snapshots: fixed missing files on restoring nagvis backup domains
* 0826 FIX: Fixed problem where user access times were not updated correctly
* 1044 FIX: Remove icon for service parameters in WATO service list for missing
services...
+ * 1056 FIX: Fixed selection of hosts for bulk actions
Notifications:
* 1042 Rule based notifications: allow matching on host groups...
diff --git a/web/htdocs/weblib.py b/web/htdocs/weblib.py
index f00ccef..2fbee11 100644
--- a/web/htdocs/weblib.py
+++ b/web/htdocs/weblib.py
@@ -78,12 +78,15 @@ def cleanup_old_selections():
def selection_id():
if not html.has_var('selection'):
sel_id = lib.gen_id()
- html.add_var('selection', sel_id)
+ html.set_var('selection', sel_id)
+ return sel_id
else:
sel_id = html.var('selection')
# Avoid illegal file access by introducing .. or /
if not re.match("^[-0-9a-zA-Z]+$", sel_id):
- return lib.gen_id()
+ new_id = lib.gen_id()
+ html.set_var('selection', new_id)
+ return new_id
else:
return sel_id