Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

storagePid in a multi-microsite scenario #747

Open
Make66 opened this issue May 25, 2023 · 4 comments
Open

storagePid in a multi-microsite scenario #747

Make66 opened this issue May 25, 2023 · 4 comments

Comments

@Make66
Copy link

Make66 commented May 25, 2023

I plan to create a view hundred sites using all the same structure based on a "template" page tree:
a) use template page tree for the design and template and content elements
b) use individual site page tree for navigation and configuration only. Linking to a) by "Show Content from Page[content_from_pid]" in page properties/Appearance

So I create a news CE in a) and set plugin.tx_news.settings.startingpoint in b) call b) in browser and all works fine (old base cal worked fine as well)

Now I put a calendarize-listonly in a) and TS setup in b) like "plugin.tx_calendarize.persistence.storagePid =" or put a constant like "calStoragePid" in b) and resolve it in a), but no events are found.
I did verify to have current event/indexes in respective pid.

Is my approach somehow clever or should I solve this differently?

@lochmueller
Copy link
Owner

The idea is right, but currently not possible. I try that the storage configuration will be part of the next release.

@Make66
Copy link
Author

Make66 commented May 26, 2023

I'll be glad to test.
Will Pizza help?

@lochmueller
Copy link
Owner

Thanks, but I need time and no pizza ;)

@rteitge
Copy link

rteitge commented May 9, 2024

Hi there,

the problem here seems to be that the TS settings are overridden by the flexform ones. Even if the flexform ones are empty. We had the same problem with felogin (there are/were also issues in forge about that). It occures in typo3 v10 and v11. It's fixed in v12, but can't be backported to v11. So we tested it with calendarize v12.4.4, there should be no problem with v13 (hopefully 😄).

Bildschirmfoto vom 2024-05-09 21-43-47
As you can see here, persistence.storagePid is empty even it's been set in TS settings. The workaround for this is to call the full TS config if the flexform storagePid is empty. It's not beautiful but it works:

commit db46a7c8dd4c1d1a62e51fe8c742c1854b9321cd (HEAD)
Author: rteitge <[email protected]>
Date:   Thu May 9 21:21:29 2024 +0200

    workaround storagePid

diff --git a/Classes/Domain/Repository/IndexRepository.php b/Classes/Domain/Repository/IndexRepository.php
index 861c2ec..4c622b1 100644
--- a/Classes/Domain/Repository/IndexRepository.php
+++ b/Classes/Domain/Repository/IndexRepository.php
@@ -610,6 +610,15 @@ class IndexRepository extends AbstractRepository
             ',',
             $frameworkConfig['persistence']['storagePid']
         ) : [];
+        if ($frameworkConfig['persistence']['storagePid'] != '' && !empty($storagePages)) {
+            return $storagePages;
+        }
+        $fullConfig = $configurationManager
+            ->getConfiguration(ConfigurationManagerInterface::CONFIGURATION_TYPE_FULL_TYPOSCRIPT)["plugin."]["tx_calendarize."];
+        $storagePages = isset($fullConfig['persistence.']['storagePid']) ? GeneralUtility::intExplode(
+            ',',
+            $fullConfig['persistence.']['storagePid']
+        ) : [];
         if (!empty($storagePages)) {
             return $storagePages;
         }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants