Kirti Savalia(OpenERP) has proposed merging 
lp:~openerp-dev/openobject-addons/trunk-bug-894434-ksa into 
lp:openobject-addons.

Requested reviews:
  Rucha (Open ERP) (rpa-openerp)
Related bugs:
  Bug #894434 in OpenERP Addons: "[6.1/trunk] wrong check : Cannot change the 
category of existing UoM; patch included"
  https://bugs.launchpad.net/openobject-addons/+bug/894434

For more details, see:
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-894434-ksa/+merge/83594
-- 
https://code.launchpad.net/~openerp-dev/openobject-addons/trunk-bug-894434-ksa/+merge/83594
Your team OpenERP R&D Team is subscribed to branch 
lp:~openerp-dev/openobject-addons/trunk-bug-894434-ksa.
=== modified file 'product/product.py'
--- product/product.py	2011-11-14 21:33:19 +0000
+++ product/product.py	2011-11-28 12:28:24 +0000
@@ -171,7 +171,7 @@
     def write(self, cr, uid, ids, vals, context=None):
         if 'category_id' in vals:
             for uom in self.browse(cr, uid, ids, context=context):
-                if uom.category_id != vals['category_id']:
+                if uom.category_id.id != vals['category_id']:
                     raise osv.except_osv(_('Warning'),_("Cannot change the category of existing UoM '%s'.") % (uom.name,))
         return super(product_uom, self).write(cr, uid, ids, vals, context=context)
 

_______________________________________________
Mailing list: https://launchpad.net/~openerp-dev-gtk
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openerp-dev-gtk
More help   : https://help.launchpad.net/ListHelp

Reply via email to