Hi,
I would like to create a PDF report using Qweb with customer address on the right side.
The res_model is 'res.partner' and here is my code
<template id="customer_payment">
<t t-call="web.html_container">
<t t-foreach="docs" t-as="o">
<t t-call="web.external_layout">
<t t-set="address">
<address t-field="o.id"
t-options='{"widget": "contact", "fields": ["name", "email", "phone"]}'/>
</t>
<div class="page">
</div>
</t>
</t>
</t>
</template>
The error appeared like this:
AttributeError: 'int' object has no attribute 'exists'
odoo.addons.base.models.qweb.QWebException: 'int' object has no attribute 'exists'
I think because 'o.id' is Integer, but other reports use 'o.partner_id' and it works.
When I delete t-options statement, the report was generated successfully without customer address.
Help me, please!
Thank you!