From f1e842bcd2072ca329db53092f33cb11bcff9818 Mon Sep 17 00:00:00 2001 From: William Henrotin Date: Wed, 21 Mar 2018 16:57:59 +0100 Subject: [PATCH] [FIX] base: khmer language (Cambodia) The code of khmer language was not the offical one. Installing it produce an error in the Babel python library. It's not possible to easily fix it by correcting the code km_KM to km_KH because Odoo prohibit changing language code. The solution to this is to remove the Khmer language from the res_lang.csv file and add it to an xml data file with the correct code. There, we can put on this record the "noupdate" tag. This tag will block any modification on the ir_model_data corresponding to the xml_id=lang_km and so avoid the error if we update the base module. Old database still wont be able to use khmer language (so we'll need to manually change it in database) but new one created after this commit will be able to use it without issue. --- odoo/addons/base/base_data.xml | 14 ++++++++++++++ odoo/addons/base/res/res.lang.csv | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/odoo/addons/base/base_data.xml b/odoo/addons/base/base_data.xml index df0eeb391d4..ed6359cdfe0 100644 --- a/odoo/addons/base/base_data.xml +++ b/odoo/addons/base/base_data.xml @@ -1,6 +1,20 @@ + + + Khmer / ភាសាខ្មែរ + km_KH + km + ltr + 1 + [3,0] + %d %B %y + %H:%M:%S + + ir.ui.menu.tree ir.ui.menu diff --git a/odoo/addons/base/res/res.lang.csv b/odoo/addons/base/res/res.lang.csv index 4f10dc3dd27..1cb9cf448ad 100644 --- a/odoo/addons/base/res/res.lang.csv +++ b/odoo/addons/base/res/res.lang.csv @@ -35,7 +35,7 @@ base.lang_de_CH,"German (CH) / Deutsch (CH)",de_CH,de_CH,"Left-to-Right","[3,3]" "base.lang_it","Italian / Italiano","it_IT","it","Left-to-Right","[3,0]",",",".","%d/%m/%Y","%H:%M:%S","True" "base.lang_ja_JP","Japanese / 日本語","ja_JP","ja","Left-to-Right","[3,0]",".",",","%Y年%m月%d日","%H時%M分%S秒","True" "base.lang_kab_DZ","Kabyle / Taqbaylit","kab_DZ","kab","Left-to-Right","[]",".",",","%m/%d/%Y","%I:%M:%S %p","True" -"base.lang_km","Khmer / ភាសាខ្មែរ","km_KM","km","Left-to-Right","[3,0]",".",",","%d %B %Y","%H:%M:%S","True" + "base.lang_ko_KP","Korean (KP) / 한국어 (KP)","ko_KP","ko_KP","Left-to-Right","[3,0]",".",",","%m/%d/%Y","%I:%M:%S %p","True" "base.lang_ko_KR","Korean (KR) / 한국어 (KR)","ko_KR","ko_KR","Left-to-Right","[3,0]",".",",","%Y년 %m월 %d일","%H시 %M분 %S초","True" "base.lang_lo_LA","Lao / ພາສາລາວ","lo_LA","lo","Left-to-Right","[3,0]",".",",","%d/%m/y","%H:%M:%S","True"