fix: 实体历史搜索的时间展示和其他时间统一为YYYY-MM-DD hh:mm:ss

This commit is contained in:
刘洪洪
2023-11-14 10:18:37 +08:00
parent c8926177f7
commit 0eb0346abc

View File

@@ -1443,7 +1443,7 @@ export const changeTimeByDate = (date) => {
const hours = Math.floor(diff / 3600)
return hours === 1 ? `${hours} ${i18n.global.t('entity.search.hourAgo')}` : `${hours} ${i18n.global.t('entity.search.hoursAgo')}`
} else {
return (new Date(oldDate).toString()).replace(/GMT.*/, '')
return date
}
}
}