Bug #102844
closedT3D Import overwrites imported timestamps (crdate, tstamp)
0%
Description
If T3D data is imported with records or pages that contain a "tstamp" and "crdate" attribute, the import will overwrite these fields with the current timestamp.
That means, the original data is overwritten.
The current behaviour relies on the TCA of a table (e.g. "tt_content" or "pages" or any custom record table), which needs to configure the ['ctrl']['tstamp']
column.
Currently, the logic can thus be circumvented (workaround) by temporarily removing this TCA configuration to import data, and then re-inserting the TCA configuration.
I'd argue that the tstamp
column is fine to be overwritten with the import date, because it is a modification of an existing record when being inserted. However the crdate
column should not be overwritten to preserve original data.
This opinion is subjective, but I think additional complexity in the Import gui for a toggle to indicate "[x] Keep original crdate" should not be required. Feedback appreciated.
A patch for this is straight-forward, the "import" context can already be deduced in the DataHandler instance and a switch be used. I'll add a patch for this.
Updated by Gerrit Code Review 10 months ago
- Status changed from New to Under Review
Patch set 1 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Gerrit Code Review 10 months ago
Patch set 2 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Gerrit Code Review 10 months ago
Patch set 3 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Gerrit Code Review 10 months ago
Patch set 4 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Gerrit Code Review 10 months ago
Patch set 5 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Gerrit Code Review 10 months ago
Patch set 6 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Garvin Hicking 10 months ago
- Assignee set to Garvin Hicking
(Note: Probably rejected: https://typo3.slack.com/archives/C03AM9R17/p1705575487463589)
Updated by Gerrit Code Review 10 months ago
Patch set 7 for branch main of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/c/Packages/TYPO3.CMS/+/82494
Updated by Stefan Bürk 10 months ago
Will abandon this patch as crdate and tsstamp should be stay core controlled.
Updated by Stefan Bürk 10 months ago
- Status changed from Under Review to Rejected
Updated by Benni Mack 10 months ago
Closing this ticket: Why? If we import data, the date of the import is important. Why is that? If we take the "original crdate", I do think we should consider the whole record lifecycle with it, and that is also sys_history to it.