diff --git a/openerp/addons/base/res/res_partner.py b/openerp/addons/base/res/res_partner.py index fe38dc89062..abfa4d3efc0 100644 --- a/openerp/addons/base/res/res_partner.py +++ b/openerp/addons/base/res/res_partner.py @@ -603,7 +603,8 @@ class res_partner(osv.osv, format_address): """ Override search() to always show inactive children when searching via ``child_of`` operator. The ORM will always call search() with a simple domain of the form [('parent_id', 'in', [ids])]. """ # a special ``domain`` is set on the ``child_ids`` o2m to bypass this logic, as it uses similar domain expressions - if len(args) == 1 and len(args[0]) == 3 and args[0][:2] == ('parent_id','in'): + if len(args) == 1 and len(args[0]) == 3 and args[0][:2] == ('parent_id','in') \ + and args[0][2] != [False]: context = dict(context or {}, active_test=False) return super(res_partner, self)._search(cr, user, args, offset=offset, limit=limit, order=order, context=context, count=count, access_rights_uid=access_rights_uid)