report - How to translate strings in RML? -
i made rml report, working perfect. in translation files, strings in rml file included, can translate content of report. there's 1 case in strings aren't recognized, hence these can't translated. i'm going set example:
next line working, "category" recognized translation files , can translate there.
<para style="terp_tblheader_general_centre">category</para>
next 1 isn't working:
<para>[[ o.type == 'r' , 'registration' or 'deregistration' ]]</para>
that unique case in strings not beingness recognized. type selection field (which can take values 'r' or 'd'), , wrote line see in study registration (in case of type valueing 'r') or deregistration (in case of type valueing 'd'). registration , deregistration not beingness recognized words translated.
i saw post:
translation of strings in python code in rml reports
and tried write _('registration')
/ _('deregistration')
, _(registration)
/ _(deregistration)
instead of 'registration'
/ 'deregistration'
, in case string don't appear in report.
anyone can help me, please?
for translation must have insert text in .po
file. check out under i18n
folder core modules sale, purchase, account.
load translation under path setting => translations => load translation
now assign language partner.
add text value in .po file
based on partner language alter text label here sample code of .rml file
<story> <para style="terp_default_8">[[repeatin(objects,'o')]]</para> <para style="terp_default_8">[[ setlang(o.partner_id.lang) ]]</para>
hope help you.
report openerp openerp-7 po rml
No comments:
Post a Comment