Bug #71712
closedStory #69617: FormEngine bugs
7 LTS: sys_file_reference IRRE elements not shown anymore in alternate languages
100%
Description
We updated from 7.5.0 to 7 LTS and suddenly, all CE with file references are not shown in BE for editing if they are in alterate languages!
BUT, the files are there, the elements are correctly linked to original content element and they are also corectly shown on the website. This concerns file links as well as simple image content elements.
The only way, we see the files in alternate languages: we copy the standard language elemnt and don't touch the copied file reference.
As soon, as we replace the copied file reference with the one from the alternate language, all is gone and nothing is shown even the thumbnails.
We have to donwgrade again, because with this bug it is not possible for our clients to maintain the website in several languages :-(
Files
Updated by Martin R. Krause about 9 years ago
I can confirm this. And this is a major stopper for all projects!
What is funny though, that images (e.g. TextMedia CE) are show in the BE in the CE preview (page module), although they are not shown as relations in the form.
It should also still be possible to edit the IRRE relation for files independently form the default language in a translated record.
Updated by Christoph Bernhard about 9 years ago
Martin R. Krause wrote:
What is funny though, that images (e.g. TextMedia CE) are show in the BE in the CE preview (page module), although they are not shown as relations in the form.
Yep, but once saved, the preview image in page module is gone as well.
Updated by Christian Kuhn about 9 years ago
- Parent task set to #69617
- Complexity changed from medium to hard
Updated by Christoph Bernhard almost 9 years ago
I just played a little bit around.
Seems, that the system is looking for field l10n_parent in Table sys_file_reference. If in field l10n_parent the correct parent record uid is set, the IRRE is shown. Else not.
The problem is, that no former sys_file_reference-record has values in fields sys_language_uid and l10n_parent! They are always 0. We have upgraded tons of files from V 4.5 to V 6.2 to V 7.5 without any problems so far
But now for 7.6:
1) if you create a new filelink CE and the do a translate action, everything is perfect (as far as for the display in BE): The translated copy of teh file link CE creates a duplicate in sys_file_reference, sets the field sys_language_uid (e.g. not 0 but 1 or 2 etc.) and also field l10n_parent correctly.
2) Then, if the translated file record is deleted and replaced with another file the fields l10n_parent and sys_language_uid of the newly created IRRE loose these original relations and are 0 again (even the field sys_language_uid, which is very strange)
3) As the result, no IRRE is displayed in BE record in alternate language
I guess in 7.5.0 displaying the IRRE record didn't depend on the l10n_parent-field in sys_file_reference but just looked up the CE languages child elements and showed any file reference pointing to that element. So field sys_file_reference.uid_foreign from tt_content must have been the key to be able to show the IRRE file records and fields sys_file_reference.sys_language_uid and sys_file_reference.l10n_parent had absolutely no influence until V 7.6.
Hope this helps.
Updated by Christoph Bernhard almost 9 years ago
Update note regarding alterante page properties. Same problem but even stranger:
Field media under resources tab does not function as well but the prevoius described action with filling in correct sys_language_uid and l10n_parent bring the files up as in IRRE elements in CE records.
Seems to be a biiiig bug. You absolutly can't use even the LTS version in production environments what is pretty a damn shit and not good for reputation at all. We downgrade every clients installation immediatly.
Updated by Markus Klein almost 9 years ago
- Category set to 978
- Target version changed from 7 LTS to Candidate for patchlevel
- Is Regression changed from No to Yes
To get the full picture we need the following steps:
a) Set up a plain 6.2.15 installation an create some relations
b) Set up a plain 7.6.0 installation and do the same
c) Set up a plain 7.6.1-dev installation and do the same
d) compare all data in the DB
e) Create fix for 7.6.1
f) (Optional; Add an upgrade wizard, which migrates data if it turns out that this is necessary.)
Updated by Markus Klein almost 9 years ago
- Status changed from New to Needs Feedback
- Target version deleted (
Candidate for patchlevel) - Is Regression changed from Yes to No
Data in 6.2¶
PageUID: 5
English (L=0) CE UID: 46
German (L=1) CE UID: 47
FileReference English: uid=24, sys_language_uid=0, l10n_parent=0, uid_local=123, uid_foreign=46
FileReference German: uid=25, sys_language_uid=1, l10n_parent=24, uid_local=123, uid_foreign=47
Data in 7.6.0¶
PageUID: 2
English (L=0) CE UID: 30
German (L=1) CE UID: 31
FileReference English: uid=6, sys_language_uid=0, l10n_parent=0, uid_local=1, uid_foreign=30
FileReference German: uid=7, sys_language_uid=1, l10n_parent=6, uid_local=1, uid_foreign=31
(also the same for current master)
Summary¶
I fail to reproduce the issue with content elements. The produced data are exactly the same in all versions and the images are always shown.
For page media though, this is an issue, since those are not created upon translation.
Updated by Markus Klein almost 9 years ago
Does it boil down to the question: "Can I use different images in translations?"
Updated by Nicole Cordes almost 9 years ago
IMHO the problem is, that children are added only if they have a valid l18n_parent (typo3/sysext/backend/Classes/Form/FormDataProvider/TcaInline.php:174) the resolved children should be added anyway. Either if they have a valid default-language-parent or they were found by the RelationHandler.
Will push a patch. Please test if it solves your problems as well.
Updated by Gerrit Code Review almost 9 years ago
- Status changed from Needs Feedback to Under Review
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45075
Updated by Christoph Bernhard almost 9 years ago
Nicole Cordes wrote:
Will push a patch. Please test if it solves your problems as well.
Hi Nicole
Yes! That solves our problem! Funny, what a simple move of end brackets can solve :-)
With the RelationHandler the inline children are showing up again.
Thank you so much!!!!
Updated by Gerrit Code Review almost 9 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/45075
Updated by Nicole Cordes almost 9 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 58f69d44af9839eb6bac4f6d6ee1b641d9f4b19a.