[i18n] [m2m] in tree view loses context

Bug #1279885 reported by Sandy Carter (http://www.savoirfairelinux.com)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Web (MOVED TO GITHUB)
New
Undecided
Unassigned
OpenERP Community Backports (Web)
Fix Released
Undecided
Unassigned

Bug Description

Problem:
Many2many fields in Tree views will not get translated.
If you check the context for a name_get of a m2m field, it is passed as None.

How to replicate:
Create Model A with a name_get, make parts of the name_get translatable.
Create Model B with a m2m reference to Model A.
Create a TreeView for B with a field for the m2m Model A.
Load translations and change language.

Expected output:
The TreeView for B will show comma-separated names for the Model A elements.
These names will be translated according to i18n.
A check of context in the name_get function while fetching the tree view will have context with the 'lang' key.

Actual output:
The TreeView for B will show comma-separated names for the Model A elements.
These names show in their original form, no localization.
A check of context in the name_get function while fetching the tree view will have context as None.

Version:
openerp-web: r4138

Related branches

Changed in ocb-web:
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.