How to get the URL of the PDF report (qweb report), for example file:///C:/Users/h/Downloads/test.pdf
Odoo is the world's easiest all-in-one management software.
It includes hundreds of business apps:
- CRM
- e-Commerce
- Accounting
- Inventory
- PoS
- Project
- MRP
This question has been flagged
Hello yasmina,
You can use below code for get url of the pdf report
base_url = self.env['ir.config_parameter'].get_param('web.base.url')
local_url = self.env['ir.attachment'].browse(new_created_attachment_pdf_report).mapped('local_url')
if base_url and local_url:
URL = base_url + '/'+ local_url
URL is final downloadable url for pdf type attachment created
Thanks & Regards,
Email: odoo@aktivsoftware.com
Skype: kalpeshmaheshwari
Enjoying the discussion? Don't just read, join in!
Create an account today to enjoy exclusive features and engage with our awesome community!
RegistracijaRelated Posts | Replies | Rodiniai | Veikla | |
---|---|---|---|---|
|
2
liep. 23
|
4900 | ||
|
1
birž. 23
|
3274 | ||
|
1
lapkr. 22
|
2926 | ||
|
1
spal. 21
|
11523 | ||
|
0
spal. 21
|
1623 |