How to display an image in a QWeb report?

后端 未结 4 770
暗喜
暗喜 2020-12-10 09:52

I extended the \'report.external_layout_footer\' qweb view to display image.

Below is my code in the file reports/external_layout.xml:



        
4条回答
  •  生来不讨喜
    2020-12-10 10:08

    In case you want to use an image that isn't static, here's what you can do instead.

    Using the company logo as an example:

    
    

    Using the mime type "image/*" will let you use different format of image and not just jpeg or just png.

    Then as odoo render by default binary data as base64, you can simply append the content of the image after base64,.

提交回复
热议问题