Bug #58352

Invalid localization overlay of cObject FILES

Added by Oliver Hader over 1 year ago. Updated about 1 year ago.

Status:Resolved Start date:2014-04-30
Priority:Should have Due date:
Assigned To:Oliver Hader % Done:

100%

Category:File Abstraction Layer (FAL) Spent time: -
Target version:-
TYPO3 Version:6.2 Is Regression:No
PHP Version:5.3 Sprint Focus:
Complexity:medium

Description

The TypoScript cObject FILES does not consider localization overlays and behavior correctly:
  • l10n_mode is not considered
  • additional translation table (e.g. for pages) is not considered correctly

Related issues

related to Core - Bug #57488: page record overlays: media field not translatable Resolved 2014-04-01
related to Core - Bug #47869: Failed localization of FILES content object related to pages Resolved 2013-05-03
related to Core - Bug #48113: typoscript FILES object always uses default language when... Resolved 2013-05-11
related to Core - Bug #57272: Extbase doesn't handle FAL translations correctly Under Review 2014-03-25
related to Core - Bug #59192: mergeIfNotBlank with FAL records Accepted 2014-05-28
related to Core - Bug #60998: PageRepository::shouldFieldBeOverlaid raises PHP warning Resolved 2014-08-15
related to Core - Bug #65863: content_fallback / mergeIfNotblank fails with content sli... Under Review 2015-03-20

Associated revisions

Revision d976053c
Added by Oliver Hader about 1 year ago

[BUGFIX] Invalid localization overlay of cObject FILES

The TypoScript cObject FILES does not consider localization
overlays and behavior correctly when it comes additional
translation table (e.g. for pages).

Concerning pages_language_overlay.media, there is no default
fallback to the values of the default language. This behavior
is the same to TYPO3 4.5. If the localization shall fallback
to the default language, the "mergeIfNotBlank" property needs
to be used for the accordant field.

For having the localization handling working properly the
FILES cObject section "references" must not set the properties
"table" and "uid" - otherwise the values will just be overriden
by those TypoScript settings.

Resolves: #58352
Resolves: #47869
Releases: 6.2
Change-Id: I8e915654e5ab1ed1eafe86411930f9fbfcc225ae
Reviewed-on: https://review.typo3.org/29739
Reviewed-by: Steffen Ritter
Tested-by: Steffen Ritter

Revision 90b0b4a3
Added by Steffen Ritter about 1 year ago

[BUGFIX] FollowUp to "Invalid localization overlay of cObject FILES"

When fixing language overlay of cObject FILES, the mocking in the unit
test was not adapted.

Resolves: #58352
Resolves: #47869
Releases: 6.2
Change-Id: I8f939e31a13e437e437624dfccddf5f39526fb8b
Reviewed-on: https://review.typo3.org/30666
Reviewed-by: Helmut Hummel
Tested-by: Helmut Hummel

History

#1 Updated by Gerrit Code Review over 1 year ago

  • Status changed from New 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/29739

#2 Updated by Oliver Hader over 1 year ago

How to test the patch:

Requirements:
  • open typo3conf/extTables.php and put
    $GLOBALS['TCA']['pages_language_overlay']['columns']['media']['l10n_mode'] = 'mergeIfNotBlank';
  • clear TCA caches (e.g. "clear all" in Install Tool)
  • create translation of a page, without translating the media field (on the resources tab)
  • have some TypoScript to out the file or the name of the file, e.g.
    @page = PAGE
    page.10 = FILES
    1. page.10.references = ...
      page.10.renderObj = TEXT
      page.10.renderObj.data = file:current:publicUrl
      page.10.renderObj.wrap = |,

Tests:
1) TypoScript using the special "fieldName" property
page.10.references.fieldName = media

2) TypoScript using stdWrap
page.10.references.field = media

#3 Updated by Frans Saris over 1 year ago

@Olly:
This doesn't work:

page.10.references.field = media

In handleFileReferences() you explicit look for fieldName or else there is a early return.

#4 Updated by Gerrit Code Review over 1 year 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/29739

#5 Updated by Gerrit Code Review over 1 year ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29739

#6 Updated by Gerrit Code Review over 1 year ago

Patch set 4 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29739

#7 Updated by Gerrit Code Review over 1 year ago

Patch set 5 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29739

#8 Updated by Gerrit Code Review over 1 year ago

Patch set 6 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29739

#9 Updated by Gerrit Code Review about 1 year ago

Patch set 7 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29739

#10 Updated by Gerrit Code Review about 1 year ago

Patch set 8 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/29739

#11 Updated by Tymoteusz Motylewski about 1 year ago

should be resolved with https://review.typo3.org/29739

#12 Updated by Steffen Ritter about 1 year ago

  • Status changed from Under Review to Resolved

#13 Updated by Gerrit Code Review about 1 year ago

  • Status changed from Resolved 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/30666

#14 Updated by Gerrit Code Review about 1 year 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/30666

#15 Updated by Gerrit Code Review about 1 year ago

Patch set 3 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/30666

#16 Updated by Steffen Ritter about 1 year ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100

Also available in: Atom PDF