From e137c9d747a72f52469090a746c23c4c291cabb4 Mon Sep 17 00:00:00 2001 From: Xavier Morel Date: Fri, 30 Nov 2012 11:36:51 +0100 Subject: [FIX] translations and other failings always include a ``context`` param in rpc requests if none is provided: use the user_context at the very least lp bug: https://launchpad.net/bugs/1084963 fixed bzr revid: xmo@openerp.com-20121130103651-4pf5bauj50cm151y --- addons/web/static/src/js/corelib.js | 3 +++ 1 file changed, 3 insertions(+) (limited to 'addons/web/static/src/js/corelib.js') diff --git a/addons/web/static/src/js/corelib.js b/addons/web/static/src/js/corelib.js index 55984162a55..f7a84e608c6 100644 --- a/addons/web/static/src/js/corelib.js +++ b/addons/web/static/src/js/corelib.js @@ -969,6 +969,9 @@ instance.web.JsonRPC = instance.web.Class.extend(instance.web.PropertiesMixin, { if (_.isString(url)) { url = { url: url }; } + _.defaults(params, { + context: this.user_context || {} + }); // Construct a JSON-RPC2 request, method is currently unused if (this.debug) params.debug = 1; -- cgit v1.2.3