[FIX] web: rpc: handle offset arg

Even if specified when building the rpc query, the offset wasn't
given in the arguments of the performed RPC.
This commit is contained in:
Aaron Bohy
2017-04-11 19:44:38 +02:00
parent 82bb35cf79
commit 357090428b
2 changed files with 3 additions and 0 deletions
+1
View File
@@ -192,6 +192,7 @@ var SearchRPCBuilder = BaseRPCBuilder.extend({
fields: this._fields,
limit: this._limit,
model: this._model,
offset: this._offset,
sort: this._orderBy
};
},
+2
View File
@@ -161,6 +161,7 @@ QUnit.module('core', {}, function () {
domain: ['a', '=', 1],
fields: ['name'],
limit: 32,
offset: 2,
model: 'partner',
sort: 'yop ASC, aa DESC',
}, "should have correct args");
@@ -170,6 +171,7 @@ QUnit.module('core', {}, function () {
.withDomain(['a', '=', 1])
.withFields(['name'])
.withLimit(32)
.withOffset(2)
.orderBy([{name: 'yop', asc: true}, {name: 'aa', asc: false}])
.exec();
});