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

[FIX] base: qweb t-call propagates t-lang #31291

Closed
wants to merge 1 commit into
base: 11.0
from

Conversation

Projects
None yet
6 participants
@kebeclibre
Copy link
Contributor

kebeclibre commented Feb 20, 2019

Before this commit, the t-lang on a t-call was not
propagated into the context's of the callee template

It resulted into mismatch translation and formatting in the final
rendered template
i.e. having a t-esc with a qweb widget float would take the wrong float format

After this commit, the t-lang parameter alters the context of the template
and t-esc with widgets are translated

OPW 1939989

Description of the issue/feature this PR addresses:

Current behavior before PR:

Desired behavior after PR is merged:

--
I confirm I have signed the CLA and read the PR guidelines at www.odoo.com/submit-pr

@kebeclibre kebeclibre requested review from mart-e , Gorash and nim-odoo Feb 20, 2019

@robodoo robodoo added the seen 🙂 label Feb 20, 2019

@C3POdoo C3POdoo added the OE label Feb 20, 2019

@kebeclibre kebeclibre force-pushed the odoo-dev:11.0-qweb-t-lang-propagate-lpe branch 2 times, most recently Feb 20, 2019

@robodoo robodoo added the CI 🤖 label Feb 20, 2019

@nim-odoo
Copy link
Contributor

nim-odoo left a comment

That definitively makes sense to do this. It seems closer to the previous translate_doc method used in the past.
However, I'm unsure of the impact this can have on a stable version.

@KangOl your input is welcomed here

@nim-odoo nim-odoo requested a review from KangOl Feb 21, 2019

@KangOl KangOl requested a review from odony Feb 21, 2019

@KangOl

KangOl approved these changes Feb 21, 2019

Copy link
Contributor

KangOl left a comment

LGTM

It's doesn't really never works?

@kebeclibre

This comment has been minimized.

Copy link
Contributor Author

kebeclibre commented Feb 21, 2019

@KangOl
nope, before the fix it did not (confirmed by @Gorash)
Plus, I did run the test without the fix, and it crashed

@Gorash

Gorash approved these changes Feb 21, 2019

Copy link
Contributor

Gorash left a comment

We saw together for the ast, with the addition of the test done it's good for me.

@KangOl

This comment has been minimized.

Copy link
Contributor

KangOl commented Feb 22, 2019

@robodoo robodoo added the r+ 👌 label Feb 22, 2019

@kebeclibre

This comment has been minimized.

Copy link
Contributor Author

kebeclibre commented Feb 22, 2019

robodoo r-

@kebeclibre

This comment has been minimized.

Copy link
Contributor Author

kebeclibre commented Feb 22, 2019

needs squashing

@robodoo robodoo removed the r+ 👌 label Feb 22, 2019

[FIX] base: qweb t-call propagates t-lang
Before this commit, the t-lang on a t-call was not
propagated into the context's of the callee template

It resulted into mismatch translation and formatting in the final
rendered template
i.e. having a t-esc with a qweb widget float would take the wrong float format

After this commit, the t-lang parameter alters the context of the template
and t-esc with widgets are translated

OPW 1939989

@kebeclibre kebeclibre force-pushed the odoo-dev:11.0-qweb-t-lang-propagate-lpe branch to 45e8148 Feb 22, 2019

@robodoo robodoo removed the CI 🤖 label Feb 22, 2019

@kebeclibre

This comment has been minimized.

Copy link
Contributor Author

kebeclibre commented Feb 22, 2019

robodoo r+

robodoo pushed a commit that referenced this pull request Feb 22, 2019

[FIX] base: qweb t-call propagates t-lang
Before this commit, the t-lang on a t-call was not
propagated into the context's of the callee template

It resulted into mismatch translation and formatting in the final
rendered template
i.e. having a t-esc with a qweb widget float would take the wrong float format

After this commit, the t-lang parameter alters the context of the template
and t-esc with widgets are translated

OPW 1939989

closes #31291
@robodoo

This comment has been minimized.

Copy link
Contributor

robodoo commented Feb 22, 2019

Merged, thanks!

@robodoo robodoo closed this Feb 22, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.