![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/0825734d7c8c67774627a5ad4871cbe6.png#pic_center)
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/be57ce974242743348458cd79204a73e.png#pic_center)
![在这里插入图片描述](https://i-blog.csdnimg.cn/blog_migrate/d0928c591b3a4b10c6ad329d00e54abe.png#pic_center)
<div class="label-style">异常时间:{{ formData.abnormalTime | formatDate('yyyy-MM-dd hh:mm:ss') }}</div>
const padDate = function (value) {
return value < 10 ? '0' + value : value
}
filters: {
formatDate: function (value) {
const date = new Date(value)
const year = date.getFullYear()
const month = padDate(date.getMonth() + 1)
const day = padDate(date.getDate())
const hours = padDate(date.getHours())
const minutes = padDate(date.getMinutes())
const seconds = padDate(date.getSeconds())
return year + '-' + month + '-' + day + '-' + ' ' + hours + ':' + minutes + ':' + seconds
}
},