aboutsummaryrefslogtreecommitdiffstats
path: root/usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js
diff options
context:
space:
mode:
authorzhangab <zhanganbing@chinamobile.com>2018-05-31 10:35:19 +0800
committerzhangab <zhanganbing@chinamobile.com>2018-05-31 10:35:27 +0800
commita3be3e341d242b8544e0f75f6bd067d9eb481df6 (patch)
tree3450b228297949e7c7dda6e6165607c3619cd76c /usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js
parented95800538cd31cc60aa5ea055ec2d3939432607 (diff)
modify alarm time display
Change-Id: Ic5c5a7657f7aa0be1b5eea071fc85a06681258bb Issue-ID: USECASEUI-124 Signed-off-by: zhangab <zhanganbing@chinamobile.com>
Diffstat (limited to 'usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js')
-rw-r--r--usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js19
1 files changed, 18 insertions, 1 deletions
diff --git a/usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js b/usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js
index 38f263d6..8dfa998b 100644
--- a/usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js
+++ b/usecaseui-monitor/src/main/webapp/app/uui/fusion/scripts/controller/alarmController.js
@@ -120,6 +120,7 @@ app.controller('pipeAlarmCtrl', ['$scope', 'ResourceAlarm', '$interval', functio
$scope.condition2 === "" ? "" : $scope.condition2, $scope.condition3 === "" ? "" : $scope.condition3,
$scope.condition4 === "" ? "" : $scope.condition4, $scope.condition5 === "" ? "" : $scope.condition5,
$scope.vfstatus).then(function (result) {
+ // console.log(result)
ctrl.displayed = result.data;
tableState.pagination.numberOfPages = result.numberOfPages;
ctrl.isLoading = false;
@@ -177,4 +178,20 @@ app.controller('pipeAlarmCtrl', ['$scope', 'ResourceAlarm', '$interval', functio
return {
getPage: getPage
};
-}]); \ No newline at end of file
+}]).filter('dateformater',function(){
+ return function(vmstime){
+ if(!vmstime){
+ return ''
+ }
+ let mstime = Number((vmstime + '').slice(0,13));
+ let time = new Date(mstime);
+ let year = time.getFullYear();
+ let month = time.getMonth() + 1;
+ let day = time.getDate();
+ let hours = time.getHours();
+ let minutes = time.getMinutes();
+ let seconds = time.getSeconds();
+ let formattime = year + '-' + month + '-' + day + ' ' + hours + ':' + minutes + ':' + seconds;
+ return formattime;
+ }
+}); \ No newline at end of file