aboutsummaryrefslogtreecommitdiffstats
path: root/fg21sim/webui
diff options
context:
space:
mode:
authorAaron LI <aaronly.me@outlook.com>2016-11-17 22:44:30 +0800
committerAaron LI <aaronly.me@outlook.com>2016-11-17 22:44:30 +0800
commit0b92218c5b815abf9c9e7cb8168a1d2f01912eb8 (patch)
treecb093d288a70f001698656085c3983ce79290c5c /fg21sim/webui
parentaa34cd9d5fc82442d852c3a89e09b0bb978a4096 (diff)
downloadfg21sim-0b92218c5b815abf9c9e7cb8168a1d2f01912eb8.tar.bz2
configs: Update logging message format
* Also update the logging messages styles for the Web UI * Show a modal notification when the task finished.
Diffstat (limited to 'fg21sim/webui')
-rw-r--r--fg21sim/webui/static/js/console.js10
1 files changed, 8 insertions, 2 deletions
diff --git a/fg21sim/webui/static/js/console.js b/fg21sim/webui/static/js/console.js
index 69b475a..6392b96 100644
--- a/fg21sim/webui/static/js/console.js
+++ b/fg21sim/webui/static/js/console.js
@@ -83,8 +83,9 @@ var appendLogMessage = function (msg) {
var ele = $("<p>").addClass("code log log-" + level);
ele.append($(log_icons[level]));
ele.append($("<span>").addClass("asctime").text(msg.asctime));
- ele.append($("<span>").addClass("levelname").text(msg.levelname));
- ele.append($("<span>").addClass("name").text(msg.name));
+ ele.append($("<span>").addClass("levelname")
+ .text("[" + msg.levelname + "]"));
+ ele.append($("<span>").addClass("name").text("<" + msg.name + ">"));
ele.append($("<span>").addClass("message").text(msg.message));
ele.appendTo("#log-messages");
};
@@ -206,6 +207,11 @@ $(document).ready(function () {
getServerTaskStatus(ajax_url)
.done(function (response) {
updateTaskStatus(response.status);
+ // Popup a modal notification
+ var modalData = {};
+ modalData.icon = "check-circle";
+ modalData.message = "Simulation task successfully finished.";
+ showModalConfigs(modalData);
});
});
} else {