Bug #56882
closedCan not translate IRRE elements
100%
Description
Translation of irre elements is buggy.
Scenario 1
IRRE tutorial is installed
- create new CE,
- go to "IRRE" tab
- create new irre element
- save
localize this element to other language
=> CE is localized, but irre elements are not
Scenario2
Create plugin with FAL field in flexform
- create CE of this plugin
- add images to the FAL field
- save
- translate this element
=> images are localized, but an additional row i shown on the list of images
When testing scenario 2 with flv files instead of images, no records were correctly localized
Files
Updated by Oliver Hader over 10 years ago
- Status changed from New to Needs Feedback
Please add the TCA field configuration for the relative parents
Updated by Oliver Hader over 10 years ago
Please use https://git.typo3.org/Packages/TYPO3.CMS.git/tree/HEAD:/typo3/sysext/core/Tests/Functional/Fixtures/Extensions/irre_tutorial (e.g. linking that from the Core sources to your typo3conf/ext/ directory), the irre_tutorial in TER or SVN is outdated for 6.2 (new version after 6.2 release).
Updated by Oliver Hader over 10 years ago
- File test_case_1.png test_case_1.png added
Could not reproduce your first test case (see test_case_1.png).
I did not check the FlexForm issue, but most likely there are problems I guess...
Updated by Tymoteusz Motylewski over 10 years ago
- File scenario1_newIrre_tutorial.png scenario1_newIrre_tutorial.png added
- File scenario1_newirre2.png scenario1_newirre2.png added
I've just tested it again with newest master version and irre_tutorial from core.
I've attached a screenshot (left side is a original record (english), right side is a translated record).
I've added new record on the left side, by clicking "create new under IRRE".
Problems:
A) if you colapse clild records, and then close the CE and open it again, you got different views depending on which record you expand first (the 1nff or IRRE). If you expand the 1nff first, then title is show correctly, but in IRRE "general" and "visibility" tabs are empty.
If you expand IRRE element first, then it is shown correctly, but the 1nff record has empty title
B) after translating the parent record (CE)there is a record visible in the 1nff, but it is missing in the IRRE section.
see right side of the screenshot
C) After adding second record to the english CE, and saving it, there are some problems in the translated CE
see screenshot scenario1_newirre2.png
notice that "Changed in original translation:" contains text
"Wellness Well-Being Hotel Rosengarten"
which is not correct - this is a title of the Hotel record with id 1, not the one associated with English CE.
Also "Localize all records" on the IRRE section doesn't work.
If you translate the record by clicking "Localize all records" in 1nff secion, then record is correctlt translated, but on the irre section it doesnt show up.
Updated by Tymoteusz Motylewski over 10 years ago
- File scenario2_mediacenter.png scenario2_mediacenter.png added
- File scenario2_B_mediacenter.png scenario2_B_mediacenter.png added
- File mediacenter.zip mediacenter.zip added
SCENARIO2:
I've attached test extension.
A) screenshot scenario2_mediacenter.png
1. Create new CE "plugin"
2. Select "mediacenter" plugin
3. Attach 2 images in the plugin flex form
4. translate record using "copy default content elements"
5. You'll get a nice exception
#1317178794: No fileusage (sys_file_reference) found for given UID. (More information)
screenshot attached (notice the getFileReferenceObject("2") call - it takes number of related images as a file reference. If we had 3 images, then it will call getFileReferenceObject("3"))
6. reload the page, edit translated record,
only one image will be visible, but grayed out. The "localize" button is not working.
B) screenshot scenario2_B_mediacenter.png
1. Create new CE "plugin"
2. Select "mediacenter" plugin
3. Attach 3 images in the plugin flex form and one flv file
4. translate record using "Language: " selectbox on the top of the site, choose "Dansk NEW" from this selectbox
5. In the tranlstaed record you will get completely wrong images, see right side of the screenshot.
Updated by Tymoteusz Motylewski over 10 years ago
attach screenshot of the exception from scenario 2A
Updated by Alexander Opitz over 10 years ago
Hi,
does this issue still exists in 6.2.4?
Updated by Tymoteusz Motylewski over 10 years ago
- File scenario2_new.png scenario2_new.png added
I've retested the issue with the recent master (Sun Jul 27 e172269f8db8720083c1e74eca03d9662a331185 ).
It is better, but the issue is NOT yet resolved.
Scenario 2:
A)
no exception any more, but after translating the record there are additional images in the localized record (see scenario2_new.png)
B)
works the same way as A) now
Updated by Alexander Opitz over 10 years ago
- Status changed from Needs Feedback to New
Updated by Gerrit Code Review about 10 years ago
- Status changed from New to Under Review
Patch set 1 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32985
Updated by Gerrit Code Review about 10 years ago
Patch set 2 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32985
Updated by Gerrit Code Review about 10 years ago
Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32986
Updated by Daniel Alder about 10 years ago
Tymoteusz Motylewski wrote:
I've retested the issue with the recent master (Sun Jul 27 e172269f8db8720083c1e74eca03d9662a331185 ).
It is better, but the issue is NOT yet resolved.Scenario 2:
A)
no exception any more, but after translating the record there are additional images in the localized record (see scenario2_new.png)
B)
works the same way as A) now
Since the function which got the releated records didn't expected a flexform xml field (pi_flexform) the ongoing process take the field as 'field with comma separated values'. In addition the 'explode' will be done over the whole xml, which is in 'pi_flexform'. So the result is not an array of IDs only. First and last array records includes the xml definitions. So the related records are incomplete as mentioned int the picture scenario2_new.png
Example:
Inline field used via TCA
Incomming field record: 1,2,3
Inline field used via flexfor
<T3FlexForms>
<data>
<sheet index="sDEF">
<language index="lDEF">
<field index="settings.irre.records">
<value index="vDEF">1,2,3</value>
</field>
</language>
</sheet>
</data>
</T3FlexForms>
The following patch will take care of this issue
Updated by Gerrit Code Review about 10 years ago
Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32986
Updated by Gerrit Code Review about 10 years ago
Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32986
Updated by Gerrit Code Review about 10 years ago
Patch set 3 for branch TYPO3_6-2 of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at http://review.typo3.org/32985
Updated by Daniel Alder about 10 years ago
- Status changed from Under Review to Resolved
- % Done changed from 0 to 100
Applied in changeset 5ee67bcaa9455126a3af4f77b7bebbf0a7545531.