Help

0

adding attachment to a view

Avatar
Nicolas LESCURE

 I want to add my "sales policies" ( a PDF files ) to sale.report_saleorder template. I tried to add it as an attachment  into a QWeb view inside this template but to no avail : the report is not automatically added to the generate PDF report.

Can I load it from within a QWeb template ? How ?

If not, what is the purpose of attachment in view ? what can be loaded ?

Any other idea is welcome.


[Odoo 10.0+e (Enterprise Edition) - hosted ]

 

2 Comments
Avatar
Discard

Why don't you add the PDF with the sales policies to the e-mail template? When you then send your sale order (quote) to the customer the sales policies are automatically added and send to your customer too.

Avatar
Nicolas LESCURE
-

That's the whole point - as far as i know, one can add just one report to the email template => currently it's the sale order - I want to have the sales policies too…hence I tried to hack the sale order report

2 Answers
1
Best Answer

Hi Nicolas,

As I can't add images/attachments to a comment I have to write an answer but I think it solves your problem anyways.
You can add multiple attachments to an e-mail template so that they get send to the customer too. 
Go to settings > Technical > Email > Templates and search for the sale order e-mail template:

Now click on the "Attachments" button to add attachments to the e-mail template and choose the file(s) you want to add:

Now save the e-mail template. Go back to your quote and click on the "send by e-mail" button. You'll now see the extra attachment added (and this will happen for every quote):

I believe this is what you're looking for?

Regards,
Yenthe

Avatar
Discard
0
Avatar
Nicolas LESCURE
Best Answer

Yes perfect 👌🏻 

Avatar
Discard