[FIX] website : reset lang variable in template

In website template,
it was not possible to use the variable "lang",
containing the current language,
as the variable was overwrote in website.layout,
in a loop context.

Changing the variable name used by the loop
solves the issue.

opw-639488
closes #6320
This commit is contained in:
Samuel Lefever 2015-04-14 19:47:48 +02:00 committed by Denis Ledoux
parent e2db33a5d4
commit f57f8c87ab
1 changed files with 2 additions and 2 deletions

View File

@ -85,8 +85,8 @@
<t t-set="languages" t-value="website.get_languages() if website else None"/>
<t t-if="request and request.website_multilang and website">
<t t-foreach="website.get_alternate_languages(request.httprequest)" t-as="lang">
<link rel="alternate" t-att-hreflang="lang['hreflang']" t-att-href="lang['href']"/>
<t t-foreach="website.get_alternate_languages(request.httprequest)" t-as="lg">
<link rel="alternate" t-att-hreflang="lg['hreflang']" t-att-href="lg['href']"/>
</t>
</t>