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.
I am trying to add a the product description field to my BOM Structure report (using the OpenOffice plugin), but can't figure out how to reference it. I am specifically referring to the large text field when editing a product under the "Information" tab. With developer tools on it says:
Field: description Object: product.product Type: text
It seems like [[ repeatIn(get_children(o.bom_lines), 'l') ]] is defining each product in the BOM line as 'l', so I tried putting in (l.description), (l.product.description), l['description'], and a few other variants, to no avail. Does anyone know the correct way to reference this? Or any references I could use to understand the syntax here better? Thanks.
For getting description of bom_lines, you need to add following : get_children method of mrp/report/bom_structure.py file:
res['pname'] = l.product_id.name # already there res['pdesc'] = l.product_id.description # add this line
Then in your rml file you can get description by adding following line:
<para style="terp_default_9">[ [[ (l['pdesc']) ]] ]</para>
Hope this may solve your issue.
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: 5/13/14, 6:42 PM|
|Seen: 1088 times|
|Last updated: 3/16/15, 8:10 AM|