-
-
Notifications
You must be signed in to change notification settings - Fork 3k
Set the page language for the preference center page if the lead's preferred locale is not set lead preferred locale #14370
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
Set the page language for the preference center page if the lead's preferred locale is not set lead preferred locale #14370
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## 6.x #14370 +/- ##
=========================================
Coverage 64.24% 64.25%
- Complexity 34573 34576 +3
=========================================
Files 2268 2268
Lines 103290 103294 +4
=========================================
+ Hits 66360 66367 +7
+ Misses 36930 36927 -3
|
…ead preferred locale
4f92c4f
to
9710c39
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you also test that the landing page locale will be used? That's the point of this PR.
app/bundles/EmailBundle/Tests/Controller/PublicControllerFunctionalTest.php
Outdated
Show resolved
Hide resolved
app/bundles/EmailBundle/Tests/Controller/PublicControllerFunctionalTest.php
Outdated
Show resolved
Hide resolved
app/bundles/EmailBundle/Tests/Controller/PublicControllerFunctionalTest.php
Outdated
Show resolved
Hide resolved
Oh, I raised an issue for a similar situation, but in Forms: #14458 Would you like to have a look? |
Co-authored-by: John Linhart <jan@linhart.email>
@escopecz, I have included a test with more scenarios. Please review. |
@shinde-rahul, let me know if you are open to making these changes part of this PR. I am also open to collaborating on this PR and adding these changes to it. |
@abhisekmazumdar, I can add you as a collaborator if you have made any progress with the solutions. You can take this ahead, or you can submit a PR against this branch, and I'll merge it. |
Thank you, @shinde-rahul, for providing collaboration access. I have added |
Given there's been substantial changes I've removed the RTC label and set it that we need a re-review on the code side and another user test. Hope that's ok! |
]; | ||
|
||
yield 'Invalid contact locale, fallback to page locale' => [ | ||
'contactLocale' => 'fr', // Assume 'yy' is not a valid locale |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why is fr
an invalid contact locale? According to the line comment, shouldn't it be yy
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is now updated to correct data. Thanks for caching this.
…b.com:shinde-rahul/mautic into use-page-language-for-preferrence-center-page
I understand that my approval may not count much since I have also made changes to this PR. However, I have reviewed the other changes, and they look good to me. |
This pull request has been mentioned on Mautic Forums. There might be relevant details there: https://forum.mautic.org/t/announcing-mautic-6-beta-now-available-for-testing/35196/1 |
Description
This PR offers to use the page language as a language of the preference center page.
The following process is used to set a language for the preference center page:
preferred contact locale --> user locale -> system locale
.This PR offers the correct/new:
preferred contact locale --> page language -> user locale -> system locale
.📋 Steps to test this PR: