Module: check_mk
Branch: master
Commit: 7a4118f8902ebf6f5d666c14e5f276d7b9f40fcd
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=7a4118f8902ebf…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Thu Oct 16 11:19:22 2014 +0200
FIX: add pending changes after creating random hosts
---
web/htdocs/wato.py | 3 +++
1 file changed, 3 insertions(+)
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index 0b44b8c..3f90051 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -4539,6 +4539,8 @@ def mode_random_hosts(phase):
folders = int(html.var("folders"))
levels = int(html.var("levels"))
created = create_random_hosts(g_folder, count, folders, levels)
+ log_pending(AFFECTED, g_folder, "create-random-hosts",
+ _("Created %d random hosts in %d folders") % (created,
folders))
return "folder", _("Created %d random hosts.") % created
else:
return "folder"
@@ -4569,6 +4571,7 @@ def create_random_hosts(folder, count, folders, levels):
created += 1
folder["num_hosts"] += count
save_folder_and_hosts(folder)
+ mark_affected_sites_dirty(folder)
reload_hosts()
return count
else: