Project

General

Profile

Actions

Feature #98240

closed

DatabaseQueryProcessor should be able to disregard language restrictions

Added by Tizian Schmidlin over 1 year ago. Updated over 1 year ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
-
Target version:
-
Start date:
2022-09-01
Due date:
% Done:

0%

Estimated time:
PHP Version:
Tags:
Complexity:
Sprint Focus:

Description

We have a card element on our site, that is built on pages records.

What it does, is get the nine first pages from the database that match the selected categories. This works fine, as long as there is no l18n_cfg involved.

View Typoscript configuration...

The part I'm interested in is tt_content.cards.dataProcessing.20.where, where I don't check for anything l18n_cfg related (yet) but when I look at the generated SQL, I see that it will always get the default language in order to be able to make the translation later.

The problem is, that this will lead to content being displayed in the default language anyway, completely disregarding l18n_cfg. I would be able to check for this in the template, but this seems inappropriate and also does not let me get 9 results everytime.

What I'd be looking for is a way to disable the language restriction on the DatabaseQueryProcessor but as far as I've seen, this is not possible?

Therefore I propose to add this in some future version of TYPO3 (or I'll build an extension that allows this, if the interest of the community is too low).

Actions #1

Updated by Tizian Schmidlin over 1 year ago

I was able to solve this, so there is no need for a core patch or anything.

The solution in our case was to extend the where with this little part:

AND (
         pages.l18n_cfg IN(1,3) AND '{page:sys_language_uid}' <> '0' OR pages.l18n_cfg NOT IN(1,3))

The new and improved version looks like this...

This issue can be closed.

Actions #2

Updated by Georg Ringer over 1 year ago

  • Status changed from New to Closed

closed as requested

Actions

Also available in: Atom PDF