Fixing product-iots#1308

Fixed https://github.com/wso2/product-iots/issues/1308
merge-requests/1/head
Dileesha Rajapakse 7 years ago
parent b255847a28
commit 4ec8894a3d

@ -163,13 +163,19 @@ function loadOperationsLog(update) {
function renderLogDetails(obj,data) {
var payload = JSON.parse(data);
var logStream = '<div class="log-data">';
var activityStatus = payload.activityStatus;
var responseMsg = null;
if (activityStatus['0'].status == "ERROR") {
responseMsg = activityStatus['0'].responses['0'].response;
}
Object.entries(payload.activityStatus).forEach(
([key, entry]) => {
logStream += '<div class="row log-entry">' +
'<div class="col-lg-8">' +
'<div class="log-status"><i class="icon fw ' + getLogStatusIcon(entry.status) + ' "></i>' +
'<span>' + entry.status + '</span></div>' +
'<span>' + ((responseMsg == null) ? entry.status : responseMsg) + '</span></div>' +
'</div>' +
'<div class="col-lg-4">' +
'<div class="log-time text-right"><span>' + entry.updatedTimestamp + '</span></div>' +

Loading…
Cancel
Save