Odoo is the world's easiest all-in-one management software. It includes hundreds of business apps:
CRM | e-Commerce | Accounting | Inventory | PoS | Project management | MRP | etc.
How to create a report with number of pages equal to order lines
For example : i have 4 lines in sale order and i have to print that report 4 times
Any body help me to solve this issue.
To achieve this, you need to add an intermediate template to this template: code
to be called from the translate_doc instead of sale.report_saleorder_lines. then in the second template we'll call sale.report_saleorder_lines template by the numbers of lines. So it'll be like:
<t t-foreach="doc_ids" t-as="doc_id">
<t t-raw="translate_doc(doc_id, doc_model, 'partner_id.lang', 'sale.report_saleorder_lines')"/>
<t t-foreach="o.order_line" t-as="l">
This will end up with report copies equal to the lines in the SO.
I hope it'll helps
Please try to give a substantial answer. If you wanted to comment on the question or answer, just use the commenting tool. Please remember that you can always revise your answers - no need to answer the same question twice. Also, please don't forget to vote - it really helps to select the best questions and answers!
About This Community
This platform is for beginners and experts willing to share their Odoo knowledge. It's not a forum to discuss ideas, but a knowledge base of questions and their answers.Register
Odoo Training Center
Access to our E-learning platform and experience all Odoo Apps through learning videos, exercises and Quizz.Test it now
|Asked: 11/11/15, 3:19 AM|
|Seen: 498 times|
|Last updated: 11/11/15, 4:36 AM|