This question has been flagged
1 Reply
3042 Views

hi all, I'm making a report which is bind to "res.partner" like below. I try to get the 'lang' but it is not work.

<report id="action_report_partner_congno" model="res.partner" string="Aging Statement" report_type="qweb-html" name="account.report_partnercongno" file="account.report_partnercongno" menu="False"/>


<template id="account.report_partnercongno" customize_show="True">

<t t-call="report.html_container">

<t t-foreach="doc_ids" t-as="doc_id">

<t t-raw="translate_doc(doc_id, doc_model, 'lang', 'account.report_partnercongno_document')"/>

</t>

</t>

</template>

Avatar
Discard
Best Answer

Hello Fanha,
Use below this code to print report (lang of partner)

<report id="action_report_partner_congno" model="res.partner" string="Aging Statement" report_type="qweb-html" name="account.report_partnercongno" file="account.report_partnercongno"/>


<t t-raw="translate_doc(doc_id, doc_model, 'commercial_partner_id.lang', 'account.report_partnercongno_document')"/> 

Avatar
Discard
Author

thx, it work! :)