中国标准时间格式化
{{time | timmer}}
过滤器如下
filters:{
timmer:function(time){
function checkTime(i){
if (i<10){
i="0" + i
}
return i;
}
var date = new Date(time);
var date_value=date.getFullYear() + '/' + (date.getMonth() + 1) + '/' + date.getDate() + ' ' + checkTime(date.getHours()) + ':' + checkTime(date.getMinutes()) + ':' + checkTime(date.getSeconds());
return date_value
}
}