Hi,
I need to display the customer name and the customer_id(which is a custom field I have created in res.partner) in the odoo Pos receipt.
For that I have loaded the fied customer_id in my js file as follows:
models.load_fields('res.partner',['customer_id']);
And in the receipt I have extended the Orderreceipt as follows:
<templates id="template" xml:space="preserve">
<t t-extend="OrderReceipt">
<t t-jquery=".pos-receipt .pos-receipt-contact" t-operation='append'>
<t t-if='receipt.client'>
<div style="font-weight:bold;">Customer:<t t-esc='receipt.client'/></div>
<div style="font-weight:bold;">ID:<t t-esc='receipt.client.customer_id'/></div>
</t>
</t>
</t>
</templates>
In the receipt it displays the customer name, but doesn't display the customer_id that I have loaded. How can I display that?
Thanks in advance.