#87819wrong format for date in drawOverrideModal dialog
Description
the override dialog within the DragUpload.js shows two wrong dates:
[snip]
Original file
readme.txt (4.6 KB)
1970-01-18 23:57
Uploaded file
readme.txt (4.6 KB)
51075-06-26 08:46
[snip]
The first date for the “Original” File might be fixed, by changing the “x” to X moment(askForOverride[i].original.mtime, ‘X’).format(‘YYYY-MM-DD HH:mm’)
(https://forge.typo3.org/projects/typo3cms-core/repository/revisions/f7a1c3856875643ecf3e5e54baa51363fb2df989/entry/typo3/sysext/backend/Resources/Public/JavaScript/DragUploader.js#L332)
The timestamp for the Uploaded file (askForOverride[i].uploaded.lastModified) looks like to be a Millisecond Timestamp so using:
moment(askForOverride[i].uploaded.lastModified, ‘x’).format(‘YYYY-MM-DD HH:mm’)
(with a small “x”) should solve this.
https://forge.typo3.org/projects/typo3cms-core/repository/revisions/f7a1c3856875643ecf3e5e54baa51363fb2df989/entry/typo3/sysext/backend/Resources/Public/JavaScript/DragUploader.js#L336
332c332
< ‘
‘ + moment(askForOverride[i].original.mtime, ‘x’).format(‘YYYY-MM-DD HH:mm’)
—-
> ‘
‘ + moment(askForOverride[i].original.mtime, ‘X’).format(‘YYYY-MM-DD HH:mm’)
336c336
< ‘
‘ + moment(askForOverride[i].uploaded.lastModified, ‘X’).format(‘YYYY-MM-DD HH:mm’)
—-
> ‘
‘ + moment(askForOverride[i].uploaded.lastModified, ‘x’).format(‘YYYY-MM-DD HH:mm’)
Reviews 0
No change resolves or names this issue in its commit message, and no comment links one.