In RPC we have to move on .py file and make script api to rpc call in python side after that move to function fetches the return value of the Python methods, converted to rpc call.For example see below code.
session.rpc('/web/dataset/resequence', {
model: some_model,
ids: array_of_ids,
offset: 42
}).then(function (result) {
// resequence didn't error out
}, function () {
// an error occured during during call
});
For instance, to call the resequence of the DataSet() controller:
Note-it does not work if you want to call the Python side of Odoo Web.
0 Comment(s)