-
Notifications
You must be signed in to change notification settings - Fork 351
Closed
Description
Q | A |
---|---|
Bug? | yes |
New Feature? | no |
Sulu Version | 1.5+, 1.6+ |
Browser Version | - |
Actual Behavior
Teaser block skip current chosen locale
ContentTeaserProvider - does not take into account locale when searching documents
Expected Behavior
Teaser block showing documents in current chosen locale
ContentTeaserProvider - take into account locale when searching documents (takes current locale)
Steps to Reproduce
- create document in several locales (example: EN & DE)
- create document with teaser block in several locales EN & DE
- choose created (on first step) document in teaser block
Current result:
- teaser block shows document in one locale (for an example EN) for both documents (EN & DE) with teaser block
Shold be:
- teaser block should contain document in same locale
Possible Solutions
Include locale when searching documents for teaser block
@@ -60,6 +60,7 @@
$searchResult = $this->searchManager
->createSearch(implode(' OR ', $statements))
->indexes($this->getPageIndexes())
+ ->locale($locale)
->execute();
/** @var QueryHit $item */
Metadata
Metadata
Assignees
Labels
No labels