Project

General

Profile

Actions

Bug #59971

closed

Reset languageMode query setting for child object queries in Extbase

Added by Alexander Stehlik over 10 years ago. Updated over 6 years ago.

Status:
Rejected
Priority:
Should have
Assignee:
-
Category:
Extbase
Target version:
-
Start date:
2014-06-29
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
6.2
PHP Version:
5.4
Tags:
Complexity:
medium
Is Regression:
No
Sprint Focus:

Description

This behavior might be intended but it would be cool if it would be configurable somehow:

I have an Extbase domain model that can not be translated. It points to a child record that is translatable.

My setting config.sys_language_mode is set to "strict".

When the language changes and the child record is not translated the parent object property will be empty (because the original object is removed during language overlay).

Should the getPreparedQuery() method in the DataMapper also reset the language mode setting by default to not destroy relations by language overlay?

$query->getQuerySettings()->setLanguageMode(NULL);

Should this be configurable? Feedback is welcome:)

An actual example of this problem can be found in the cz_simple_cal Extension. The index entries point to single events that might be translated or not. How would you handle this with language mode "strict"? Enhance the event index query, so that only index records are found where a translation exists?


Related issues 2 (0 open2 closed)

Related to TYPO3 Core - Bug #50031: Ordering changes result if multilanguage contentClosed2013-07-15

Actions
Related to TYPO3 Core - Bug #82363: Make Extbase translation handling consistent with typoscriptClosedTymoteusz Motylewski2017-09-07

Actions
Actions #1

Updated by Gerrit Code Review over 10 years 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/31227

Actions #2

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/31227

Actions #3

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/31227

Actions #4

Updated by Oliver Eglseder about 10 years ago

How would you configure another LanguageMode for child objects then?

Actions #5

Updated by Alexander Stehlik about 10 years ago

I don't really have an answer for this yet. But I see these possibilities:

  • TCA
  • Annotations in the Domain model
Actions #6

Updated by Oliver Eglseder about 10 years ago

But then you won't have the chance to do it in a specific repository method, which i think is the place where setting languageMode for a query and object property queries is needed most.

Actions #7

Updated by Alexander Stehlik about 10 years ago

You still can use setLanguageMode() in your own queries in your repository. This patch only indents to adjust the behavior of child object queries that are used by the DataMapper.

Actions #8

Updated by Gerrit Code Review over 9 years ago

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

Actions #9

Updated by Gerrit Code Review over 9 years ago

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

Actions #10

Updated by Gerrit Code Review about 9 years ago

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

Actions #11

Updated by Gerrit Code Review over 8 years 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/31227

Actions #12

Updated by Gerrit Code Review over 8 years 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/31227

Actions #13

Updated by Gerrit Code Review almost 8 years ago

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

Actions #14

Updated by Gerrit Code Review over 7 years ago

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

Actions #15

Updated by Tymoteusz Motylewski about 7 years ago

  • Related to Bug #82363: Make Extbase translation handling consistent with typoscript added
Actions #16

Updated by Anja Leichsenring over 6 years ago

  • Status changed from Under Review to Rejected

closed in favor of #82363

Actions

Also available in: Atom PDF