Inconsistent behaviour in _inherits

Bug #303455 reported by Pedro Tarrafeta (Acysos)
12
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Odoo Server (MOVED TO GITHUB)
Fix Released
Wishlist
Thibaut DIRLIK (Logica)

Bug Description

If one object _inherits from another (like product.product from product.template) and both objects have a column with the same name, the value of the father is shown in the view, however when saving the child object, the child's table is written.

Example:

Try to move 'weight' field from product.template to product.product. You can define a 'weight' column for product.product. When you open the product form, the displayed 'weight' will be the one retrieved from the product_template table, but if you change the value and save it, the value will be saved on the product_product table.

Expected behaviour: When the same column exists in both, parent and child, the child's value should be used.

Related branches

Revision history for this message
Fabien (Open ERP) (fp-tinyerp) wrote :

Hello,

This will not be fixed for 5.0, I suggest to create a blueprint that will be assigned to a futur release.
I close the bug.

Thanks.

Changed in openobject-server:
status: New → Won't Fix
Revision history for this message
Thibaut DIRLIK (Logica) (thibaut-dirlik) wrote :

Hi,

The 6.1 is soon here, and this should be fixed. Smetimes we can avoid using same fields name, but sometimes we can't (i.e: "active"). I don't think it's a hudge patch, and it would make _inherits more usable.

Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

As requested, reopening the bug and assigning to Thibaut. Hope the community will be able to review your merge proposal soon :-)
Thanks for working on this!

Changed in openobject-server:
assignee: nobody → Thibaut DIRLIK (Logica) (thibaut-dirlik)
importance: Undecided → Wishlist
status: Won't Fix → Confirmed
Revision history for this message
Olivier Dony (Odoo) (odo-openerp) wrote :

Thibaut's fix landed in trunk at revision 3841 revid: <email address hidden>.

Well done, and thanks again!

Changed in openobject-server:
milestone: none → 6.1
status: Confirmed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.