Module: check_mk
Branch: master
Commit: 5c3a30694549bd654d18395486357082f4991c57
URL:
http://git.mathias-kettner.de/git/?p=check_mk.git;a=commit;h=5c3a30694549bd…
Author: Mathias Kettner <mk(a)mathias-kettner.de>
Date: Wed Dec 26 11:16:26 2012 +0100
WATO: Tune activation page, omit page reload
---
web/htdocs/images/repprogress.png | Bin 200 -> 199 bytes
web/htdocs/js/wato.js | 10 +++++-----
web/htdocs/wato.css | 10 ++++++++--
web/htdocs/wato.py | 10 ++++++++--
4 files changed, 21 insertions(+), 9 deletions(-)
diff --git a/web/htdocs/images/repprogress.png b/web/htdocs/images/repprogress.png
index ad02c31..5a85786 100644
Binary files a/web/htdocs/images/repprogress.png and b/web/htdocs/images/repprogress.png
differ
diff --git a/web/htdocs/js/wato.js b/web/htdocs/js/wato.js
index a058dde..acdd16c 100644
--- a/web/htdocs/js/wato.js
+++ b/web/htdocs/js/wato.js
@@ -513,7 +513,7 @@ function wato_activation_result(siteid, code) {
oMsg.innerHTML = code.substr(3);
// Reload page after 2 secs
- setTimeout(wato_replication_finish, 2000);
+ setTimeout(wato_replication_finish, 1000);
} else {
oState.innerHTML = '';
oMsg.innerHTML = code;
@@ -571,24 +571,24 @@ function wato_replication_result(siteid, code) {
oDiv.innerHTML = code;
if (0 == num_replsites) {
- setTimeout(wato_replication_finish, 2000);
+ setTimeout(wato_replication_finish, 1000);
}
}
function wato_replication_finish() {
// check if we have a sidebar-main frame setup
- if(this.parent && parent && parent.frames[1] == this)
+ if (this.parent && parent && parent.frames[1] == this)
parent.frames[0].location.reload(); // reload sidebar
// always reload main
- this.location.reload();
+ // this.location.reload();
var oDiv = document.getElementById("act_changes_button");
oDiv.style.display = "none";
oDiv = null
// Hide the pending changes container
var oPending = document.getElementById("pending_changes");
- if(oPending) {
+ if (oPending) {
oPending.style.display = "none";
oPending = null
}
diff --git a/web/htdocs/wato.css b/web/htdocs/wato.css
index 24ff34f..0bcaa3d 100644
--- a/web/htdocs/wato.css
+++ b/web/htdocs/wato.css
@@ -833,10 +833,11 @@ div.varname {
background-image: url("images/repprogress.png");
background-repeat: repeat;
float: left;
- color: white;
text-align: center;
- padding-top: 0px;
+ padding-top: 4px;
font-size: 8pt;
+ box-shadow: 0.5px 0.5px 1px #224466 inset;
+ color: black;
}
.wato td.tag-ellipsis {
@@ -847,6 +848,11 @@ div.varname {
-o-text-overflow: ellipsis;
}
+.wato td#repmsg_local {
+ width: 280px;
+}
+
+
/*-------------------------------------------------------------------------.
| ____ |
| | _ \ _ __ ___ __ _ _ __ ___ ___ ___ |
diff --git a/web/htdocs/wato.py b/web/htdocs/wato.py
index e8a0035..95d7236 100644
--- a/web/htdocs/wato.py
+++ b/web/htdocs/wato.py
@@ -7242,7 +7242,8 @@ def ajax_activation():
# html.message
html.write('OK: ')
- html.write('<div class=act_success><img
src="images/icon_apply.png" /> %s</div>' % _("The new
configuration has been successfully activated."))
+ html.write('<div class=act_success><img
src="images/icon_apply.png" /> %s</div>' %
+ _("Configuration successfully activated."))
except Exception, e:
html.show_error(str(e))
@@ -11730,7 +11731,12 @@ def render_folder_path(the_folder = 0, link_to_last = False,
keepvarnames = ["mo
html.sorted_select(
"folder", [ ("", "") ] + options,
onchange = "folderpath.submit();",
- attrs = {"class" : "folderpath"}
+ attrs = {
+ "class" : "folderpath",
+ # This does not work: it prevents the selection from
+ # being unfolded
+ # "onfhocus" : "if (this.blur) this.blur();",
+ }
)
for var in keepvarnames:
html.hidden_field(var, html.var(var))