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

Multilanguage Issue with extended powermail classes #53

Open
mkrappitz opened this issue Feb 15, 2021 · 3 comments
Open

Multilanguage Issue with extended powermail classes #53

mkrappitz opened this issue Feb 15, 2021 · 3 comments

Comments

@mkrappitz
Copy link

mkrappitz commented Feb 15, 2021

We had the following use case: TYPO3 10.4.12 and EXT:powermail 8.2.4 and EXT:powermail_cond 8.0.1 (also tried 8.0.3 from github) and subclassed Powermail Domain Model Classes because of extra TCA fields done the following way with XCLASS + registerImplementation() instead of using config.tx_extbase.objects TS (as it is still in the official EXT:powermail documentation btw.):
https://docs.typo3.org/c/typo3/cms-core/master/en-us/Changelog/9.5/Deprecation-86270-ExtbaseXclassViaTypoScriptSettings.html

This had the side effect that the EXT:powermail_cond rules JSON was only being filled with data in default language, but not in translation languages of the frontend because \In2code\PowermailCond\Controller\ConditionController::buildConditionAction() line 65 returned no Condition Container in translated frontend languages. So a quick and easy solutation was for us to change this line from:
$conditionContainer = $containerRepository->findOneByForm($form);
to
$conditionContainer = $containerRepository->findOneByForm($form->getUid());

Now we have the EXT:powermail_cond rules json data again in all languages. I guess it had to do with $form not being not of class \In2code\Powermail\Domain\Model\Form but in our case of \OURVENDER\Ourextension\Domain\Model\Form. But I'm not exactly sure.

@mschwer
Copy link

mschwer commented Feb 22, 2021

I had the same problem with powermail_cond rules in combination with translated forms. Your solution is solving the problem. Would be nice to be fixed officialy, so we don't have to exclude the extension from updates :-)
Thank you!

@fazzyx
Copy link

fazzyx commented Mar 18, 2021

TYPO3: 10.4 / Powermail: 8.2.4 / powermail_cond: 8.1.0
We have the same problem but we don't use subclasses.
The workaround (or fix) had solved it.
Thanks to @mkrappitz!

@buerowilhelm
Copy link

Same problem here with translated forms. Everything works fine with this solution!
THANKS @mkrappitz !

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

No branches or pull requests

5 participants