From 39cbfcbec802dbd8d98b4b4cb9bc637266206c7b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A9dric=20Krier?= Date: Wed, 9 Oct 2013 18:25:39 +0200 Subject: [PATCH] Fix usage of context company Default value of company should be -1 to get the right cast and an impossible value. Replace False by None as other value in "in" clause. issue3394 review1119002 --- price_list.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/price_list.py b/price_list.py index 815256bd69..bc3fa15d37 100644 --- a/price_list.py +++ b/price_list.py @@ -52,7 +52,7 @@ class PriceList(ModelSQL, ModelView): company = fields.Many2One('company.company', 'Company', required=True, select=True, domain=[ ('id', If(Eval('context', {}).contains('company'), '=', '!='), - Eval('context', {}).get('company', 0)), + Eval('context', {}).get('company', -1)), ]) lines = fields.One2Many('product.price_list.line', 'price_list', 'Lines')