Hello odoo Family,
I am really new to odoo and qweb but I have to modify the standard account.invoice report for our company. I am familiar with HTML, so qweb itself is not a problem, however I really struggle with implementing additional data to the report. We use odoo version 9.0e.
This is my situation:
We have several warehouses in odoo. Each of them has a unique image (logo) attached to it's address (res.partner?). This logo should also appear in the account.invoice report when the products of that report are linked to that specific warehouse.
I think I'm doing something terribly wrong here, but this what I have so far:
<img t-if="o.invoice_line_ids[0].product_id.warehouse_id.partner_id.image" t-att-src="'data:image/png;base64,%s' % o.invoice_line_ids[0].product_id.warehouse_id.partner_id.image" align="right" style="max-height: 20px;"/>I don't think that I can load the stock model that easily in qweb's account.invoice model? I am only using the first product of the report to identify the warehouse because this always works in our environment.
So my initial question here is:
How can I get the image of the warehouse of the first product in the report?
The second thing is the following:
How can I get the shipping address and the billing address of the specific order. Everything I tried din't work out as expected and I get despaired of this more and more...
Best reagards,
Timo