Open PDF Reports and PDF Attachments in Browser

by ,
Odoo 14
v 13.0 Third Party 12236
Download for v 13.0 Deploy on Odoo.sh Live Preview
Availability
Odoo Online
Odoo.sh
On Premise
Lines of code 88
Technical Name prt_report_attachment_preview
LicenseLGPL-3
Websitehttps://cetmix.com
Versions 17.0 16.0 11.0 12.0 13.0 14.0 15.0 10.0
You bought this module and need support? Click here!
Availability
Odoo Online
Odoo.sh
On Premise
Lines of code 88
Technical Name prt_report_attachment_preview
LicenseLGPL-3
Websitehttps://cetmix.com
Versions 17.0 16.0 11.0 12.0 13.0 14.0 15.0 10.0

Open PDF Reports in browser

Main features

  • Preview PDF reports in browser instead of downloading
  • Download reports later from browser if you need (filename will be preserved)
  • Note: you must enable pop-up windows for Odoo when prompted!

Other useful apps

Support

  • Tested on Odoo Community v13.0
  • Russian language translation
  • English, German and Russian language support
  • Click to contact us for support or any custom app you need

Click here for more addons!

Click to contact us for support or any custom addons you need

Before

After

Click to try it!

Click to contact us for support

Icon and frame vector created by Freepik

Please log in to comment on this module

  • The author can leave a single reply to each comment.
  • This section is meant to ask simple questions or leave a rating. Every report of a problem experienced while using the module should be addressed to the author directly (refer to the following point).
  • If you want to start a discussion with the author, please use the developer contact information. They can usually be found in the description.
Please choose a rating from 1 to 5 for this module.
Works as advertised
by
Guy Clerx
on 12/2/21, 8:37 AM

Thank you.
Worked instantly (14CE)


Great, but has an issue
by
Jerson
on 4/7/21, 12:39 PM

Hi.

I've used this module on Odoo 11 Community version before and was very satisfied with it. However, now I'm using version 14, Community and after I print a report from a button in form, all the buttons in my form are blocked (Edit, Create, Print Buttons, State buttons). To unlock the buttons, I have to refresh the page, which is not good at all.

If this issue was solved, it would be the perfect module.

Best regards,

Jerson Figueiredo

Re: Great, but has an issue
by
Ivan Sokolov
on 4/7/21, 3:11 PM Author

Hi Jerson,

Thank you for your feedback!
Please update to the latest version and try again.

Best regards,
Ivan Sokolov


Error if PDF file name is not in ASCII character set
by
hui zhang
on 9/11/20, 8:27 AM
  • An error log:

    Traceback (most recent call last):
    File "/opt/odoo13/odoo-venv/lib/python3.6/site-packages/werkzeug/serving.py", line 304, in run_wsgi
    execute(self.server.app)
    File "/opt/odoo13/odoo-venv/lib/python3.6/site-packages/werkzeug/serving.py", line 295, in execute
    write(data)
    File "/opt/odoo13/odoo-venv/lib/python3.6/site-packages/werkzeug/serving.py", line 258, in write
    self.send_header(key, value)
    File "/usr/lib/python3.6/http/server.py", line 508, in send_header
    ("%s: %s\r\n" % (keyword, value)).encode('latin-1', 'strict'))
  • To ensure a valid filename, use UTF-8

  • Modify the prt_report_attachment_preview\controllers\cetmix_controllers.py:54

  • pdfhttpheaders = [('Content-Type', 'application/pdf'), ('Content-Length', len(pdf)),
    ('Content-Disposition', 'filename="%s.pdf"' % filepart.encode('utf-8'))]
Re: Error if PDF file name is not in ASCII character set
by
Ivan Sokolov
on 9/11/20, 9:16 AM Author

Thank you for feedback!


by
rose_99_02@hotmail.com
on 12/8/19, 11:41 PM

Screen video has been sent to support@cetmix.com


by
rose_99_02@hotmail.com
on 12/8/19, 7:43 AM

Normal installation When I click on a report, the URL is the same as the one shown on your picture, but there is no way to display the PDF What's the problem? There's no hint in the middle

Re:
by
Ivan Sokolov
on 12/8/19, 10:49 AM Author

Hi, Thank you for reporting. Could you please share some screen video to support@cetmix.com?


ERROR
by
nixon
on 10/22/19, 9:34 PM

Exception thrown and not caught http://localhost:8069/web/content/441-142dd78/web.assets_common.js:3804 Traceback: TypeError: invalid type format at parse (http://localhost:8069/web/content/441-142dd78/web.assets_common.js:3804:59) at xhr.onload (http://localhost:8069/web/content/441-142dd78/web.assets_common.js:3843:202)

Re: ERROR
by
Ivan Sokolov
on 10/26/19, 10:06 AM Author

Hi Nixon, Thank you for your feedback! Which report are you trying to print?