diff --git a/addons/stock/models/stock_warehouse.py b/addons/stock/models/stock_warehouse.py index 3fee34a4ee8..a580f071848 100644 --- a/addons/stock/models/stock_warehouse.py +++ b/addons/stock/models/stock_warehouse.py @@ -791,7 +791,7 @@ class Orderpoint(models.Model): ('qty_multiple_check', 'CHECK( qty_multiple >= 0 )', 'Qty Multiple must be greater than or equal to zero.'), ] - @api.constrains('product_id', 'product_uom') + @api.constrains('product_id') def _check_product_uom(self): ''' Check if the UoM has the same category as the product standard UoM ''' if any(orderpoint.product_id.uom_id.category_id != orderpoint.product_uom.category_id for orderpoint in self): diff --git a/openerp/addons/base/ir/ir_ui_view.py b/openerp/addons/base/ir/ir_ui_view.py index cbef198c820..254cfc416f9 100644 --- a/openerp/addons/base/ir/ir_ui_view.py +++ b/openerp/addons/base/ir/ir_ui_view.py @@ -271,7 +271,7 @@ actual arch. self.raise_view_error(message, self.id) return True - @api.constrains('arch', 'arch_base') + @api.constrains('arch_db') def _check_xml(self): # Sanity checks: the view should not break anything upon rendering! # Any exception raised below will cause a transaction rollback.