← Back to team overview

openerp-community-reviewer team mailing list archive

lp:~akretion-team/openerp-product-attributes/fix-product-attribute-group into lp:openerp-product-attributes

 

arthru has proposed merging lp:~akretion-team/openerp-product-attributes/fix-product-attribute-group into lp:openerp-product-attributes.

Requested reviews:
  Product Core Editors (product-core-editors)
Related bugs:
  Bug #1231502 in OpenERP Product Attributes: "ValueError when copying a product with custom attributes"
  https://bugs.launchpad.net/openerp-product-attributes/+bug/1231502

For more details, see:
https://code.launchpad.net/~akretion-team/openerp-product-attributes/fix-product-attribute-group/+merge/187814

The bug cause is that the attribute group field on the product is a one2many (whereas it should have been a many2many). The product's copy function was then trying to copy the attribute group...


-- 
https://code.launchpad.net/~akretion-team/openerp-product-attributes/fix-product-attribute-group/+merge/187814
Your team Product Core Editors is requested to review the proposed merge of lp:~akretion-team/openerp-product-attributes/fix-product-attribute-group into lp:openerp-product-attributes.
=== modified file 'product_custom_attributes/product.py'
--- product_custom_attributes/product.py	2013-07-10 09:56:22 +0000
+++ product_custom_attributes/product.py	2013-09-26 15:06:48 +0000
@@ -44,7 +44,7 @@
 
     _columns = {
         'attribute_set_id': fields.many2one('attribute.set', 'Attribute Set'),
-        'attribute_group_ids': fields.function(_attr_grp_ids, type='one2many',
+        'attribute_group_ids': fields.function(_attr_grp_ids, type='many2many',
         relation='attribute.group', string='Groups')
     }
 


Follow ups