summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/boot.js
diff options
context:
space:
mode:
authorGéry Debongnie <ged@odoo.com>2016-05-25 12:18:48 +0200
committerGéry Debongnie <ged@odoo.com>2016-05-30 09:23:07 +0200
commit9c68bc74827864a3c6c21be8ead1b2ed3d122d73 (patch)
treee9dec0618783fbce6d12e89369fa064c63dc886b /addons/web/static/src/js/boot.js
parent2a8a17024d2b46f3f8837a8672334a7dff3abd1b (diff)
[REF] point_of_sale,web(site): move session info into page source
This commit introduces a mechanism to add information into the session from a different module, without having to fetch it manually with a rpc. This is intended to be used with small pieces of info required at the start of the web client, such as currency informations. To add information to the session, one can simply inherit from ir.http and modify the session_info method.
Diffstat (limited to 'addons/web/static/src/js/boot.js')
-rw-r--r--addons/web/static/src/js/boot.js5
1 files changed, 3 insertions, 2 deletions
diff --git a/addons/web/static/src/js/boot.js b/addons/web/static/src/js/boot.js
index 666520b263d..2cc4abe29bb 100644
--- a/addons/web/static/src/js/boot.js
+++ b/addons/web/static/src/js/boot.js
@@ -47,7 +47,8 @@
var debug = ($.deparam($.param.querystring()).debug !== undefined);
- var odoo = window.odoo = {
+ var odoo = window.odoo = window.odoo || {};
+ _.extend(odoo, {
testing: typeof QUnit === "object",
debug: debug,
remaining_jobs: jobs,
@@ -253,7 +254,7 @@
return services;
}
- };
+ });
// automatically log errors detected when loading modules
var log_when_loaded = function () {