mirror of
https://repository.entgra.net/community/device-mgt-core.git
synced 2025-10-06 02:01:45 +00:00
Fixing product-iots#1322
Fixed https://github.com/wso2/product-iots/issues/1322
This commit is contained in:
parent
c6d6d61df6
commit
c41a704a35
@ -46,6 +46,22 @@ $(document).ready(function() {
|
|||||||
|
|
||||||
});
|
});
|
||||||
|
|
||||||
|
function getLogStatusIcon(entry) {
|
||||||
|
switch (entry) {
|
||||||
|
case 'COMPLETED':
|
||||||
|
return 'fw-success'
|
||||||
|
break;
|
||||||
|
case 'PENDING':
|
||||||
|
return 'fw-pending'
|
||||||
|
break;
|
||||||
|
case 'ERROR':
|
||||||
|
return 'fw-error'
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
return 'fw-info'
|
||||||
|
}
|
||||||
|
};
|
||||||
|
|
||||||
function loadOperationsLog(update) {
|
function loadOperationsLog(update) {
|
||||||
var operationsLogTable = "#operation-log";
|
var operationsLogTable = "#operation-log";
|
||||||
if (update) {
|
if (update) {
|
||||||
@ -95,7 +111,7 @@ function loadOperationsLog(update) {
|
|||||||
data: "status",
|
data: "status",
|
||||||
class: "text-right extended-log-data log-record-status",
|
class: "text-right extended-log-data log-record-status",
|
||||||
render: function(data, type, full, meta) {
|
render: function(data, type, full, meta) {
|
||||||
return '<i class="icon fw fw-success"></i><span> ' + data + ' </span><i class="icon fw fw-down"></i>';
|
return '<i class="icon fw ' + getLogStatusIcon(data) + '"> </i><span> ' + data + ' </span><i class="icon fw fw-down"></i>';
|
||||||
},
|
},
|
||||||
width: "100%"
|
width: "100%"
|
||||||
}
|
}
|
||||||
@ -171,10 +187,13 @@ function loadOperationsLog(update) {
|
|||||||
case 'PENDING':
|
case 'PENDING':
|
||||||
return 'fw-pending'
|
return 'fw-pending'
|
||||||
break;
|
break;
|
||||||
|
case 'ERROR':
|
||||||
|
return 'fw-error'
|
||||||
|
break;
|
||||||
default:
|
default:
|
||||||
return 'fw-info'
|
return 'fw-info'
|
||||||
}
|
}
|
||||||
}
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user