Le 2 sept. 09 à 12:39, [email protected] a écrit : > you can inherit view like this and change on_change of product id. > here is the sample code to change product_id in invoice_lines. > > <record id="view_invoice_line_gen_form_multi_company" > model="ir.ui.view"> > <field > name="name">account.invoice.line.form</field> > <field > name="model">account.invoice.line</field> > <field name="type">form</ > field> > <field name="inherit_id" > ref="account.view_invoice_line_form"/> > <field name="arch" > type="xml"> > <xpath > expr="/form/notebook/page/field[@name='product_id']" > position="replace"> > > <field name="product_id" > on_change="product_id_change(product_id, uos_id, quantity, > name, parent.type, parent.partner_id, parent.fiscal_position, > price_unit, parent.address_invoice_id, {'company_id': > parent.company_id})"/> > </xpath> > </field> > </record>
Thanks a lot ! This solved my problem. And from a technical point of view, it's a very interesting possibility for my future devs. Michel _______________________________________________ Tinyerp-users mailing list http://tiny.be/mailman2/listinfo/tinyerp-users
