-
- Downloads
[FIX] account: missing translation
- Install a second language, e.g. French - Set Parter A language to French - Create an invoice for A with a date due in the past - On the partner form view, print the 'Due Payments' The body of the letter is not translated in French. Something quite weird appears: - The corresponding string is exported in the `stock` module - It is linked to the demo data `stock.res_company_1`, which corresponds to 'My Company, Chicago'. Therefore, the translation cannot be found by the corresponding query generated in `_generate_translated_field` and `_read_from_database`: ``` SELECT "res_company"."id" as "id",COALESCE("res_company__overdue_msg"."value", "res_company"."overdue_msg") as "overdue_msg" FROM "res_company" LEFT JOIN (SELECT DISTINCT ON (res_id) res_id, value FROM "ir_translation" WHERE name='res.company,overdue_msg' AND lang='fr_BE' AND value!='' ORDER BY res_id, id DESC) as "res_company__overdue_msg" ON ("res_company"."id" = "res_company__overdue_msg"."res_id") WHERE "res_company".id = 1 ORDER BY "res_company"."sequence" ,"res_company"."name" ``` Indeed, `res_company.id` is 1, while `res_company__overdue_msg.res_id` is 3. The root cause has been solved in v11, to we only export the necessary term. opw-1908337 closes odoo/odoo#29525
Loading
Please register or sign in to comment