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.
Hi, First of all I had a new parameter to the product. Then I need that new parameter in Sales Order Lines for each product in the sales order.
I've tried to add but I had some problems regarding to being inheriting a view from sales.order and adding a parameter from products.
I've done this:
<record id="view_order_form_inherit" model="ir.ui.view"> <field name="name">sale.order.form.inherit</field> <field name="model">sale.order</field> <field name="inherit_id" ref="sale.view_order_form"/> <field name="arch" type="xml"> <xpath expr="/form/sheet/notebook/page/field[@name='order_line']/tree/field[@name='price_unit']" position="before"> <field name="new_field_from_product"/> </xpath> </field> </record>
Thanks, sorry my English.
First, The code you posted is trying to insert your new field into the view_ORDER_form, you need to insert it on the view_ORDER_LINE_form.
Second, the python code must also inherit and add the new field, if you are not doing that, there is no way your XML will work right.
Third, when you ask for help, please include the error message. Without the error message those trying to help you are flying blind.
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: 3/18/13, 3:07 PM|
|Seen: 6004 times|
|Last updated: 3/16/15, 8:10 AM|