Help

3

How to print two different invoice layouts?

Avatar
Dariusz Kubiak

I have two invoice layouts: account_print_invoice.rml and account_print_invoice_new.rml I want to add second print action to Print button on invoice form. I duplicated invoice records in Reports and Action Bindings. Reports / Name: Invoice New Reports / Report File: account/report/account_print_invoice_new.rml Action Binding / Name: Invoice New Action Binding / Action Reference: ir.actions.report.xml,335 - which links to Reports / Invoice New All the rest of values are the same as default. Action Binding / Qualifier: client_print_multi

Now Invoice / Print button has two action: Invoice and Invoice New, which is correct. THE PROBLEM is both print the same layout account_print_invoice_new.rml. I can not print the default account_print_invoice.rml. Why???

I changed Report / Report File in Invoice New to default layout: account/report/account_print_invoice.rml and both print actions use the same DEFAULT layout. Look like OpenERP takes only one last print action from ir.actions.report.xml with report_name = 'account.invoice'.

What's wrong? Is it a BUG???

1 Comment
Avatar
Discard
Avatar
phoebe
-

Same problem ! waiting for answers.

2 Answers
1
Avatar
David Birchmier
Best Answer

I created a step by step guide with screenshots on how to do this using Odoo v8. I struggled with this for a long time (being new to Odoo myself) and I hope this guide will help save others the same frustration I went through.

Here's the guide to Create Multiple Invoice Templates in Odoo v8:
http://www.askmpa.com/creating-multiple-invoice-templates-in-odoo-v8/

Avatar
Discard
0
Avatar
OpenERP Vietnam
Best Answer

You go to Settings - Technical - Actions - Reports.

Find the report that you modifined. Then you delete all thing at field Save as Attachment Prefix and uncheck at field Reload from Attachment. The new report of you will be affected.

Avatar
Discard