[FIX] web: prevent kwargs position confusion

The fith arguemnt of the search method in count in new API.
Passing all arguments as positional arguments will make the context passed for
the value of the `count` argument.

bbc67ec is a similar fix in 9.0

Closes #12830
This commit is contained in:
Stefan Rijnhart 2016-07-18 16:51:57 +02:00 committed by Martin Trigaux
parent 17a1304285
commit 2757ec3d0c
No known key found for this signature in database
GPG Key ID: 7B0E288E7C0F83A7
1 changed files with 1 additions and 1 deletions

View File

@ -1432,7 +1432,7 @@ class ExportFormat(object):
Model = request.session.model(model)
context = dict(request.context or {}, **params.get('context', {}))
ids = ids or Model.search(domain, 0, False, False, context)
ids = ids or Model.search(domain, offset=0, limit=False, order=False, context=context)
if not request.env[model]._is_an_ordinary_table():
fields = [field for field in fields if field['name'] != 'id']