translation i18n

Asked by julien M.

Hello,

I try to translate a module using i18n, but I don't know what are the "#: ..."

Someone would have more details on this subject ?

Thanks

Question information

Language:
English Edit question
Status:
Solved
For:
Odoo Addons (MOVED TO GITHUB) Edit question
Assignee:
No assignee Edit question
Solved by:
Anup(SerpentCS)
Solved:
Last query:
Last reply:
Revision history for this message
Best Anup(SerpentCS) (anup-serpent) said :
#1

Hello Julien M,

You'll find the following entries in po files for a particular term to be translated.

#. module: base
#: model:res.country,name:base.sh
msgid "Saint Helena"
msgstr ""

The first #. module states that its a module in which the translation belongs too..

The second #: model/<name> this specifies the translation type which can be model,field,view etc. and also contains the name of the particular.

The third msgid " " will be the term to be translated we'll call it the source.

And finally the fourth one msgstr " " indicates the translation.

you can check the code for it in the tools/tranlate.py and you can also check the table ir_translations which create entries for all the translations when a particular language is installed along with the module being installed.

Thanks.

Revision history for this message
julien M. (sanguinator-x) said :
#2

Thanks Anup (Open ERP), that solved my question.