diff options
| author | Antony Lesuisse <al@openerp.com> | 2011-09-27 13:14:02 +0200 |
|---|---|---|
| committer | Antony Lesuisse <al@openerp.com> | 2011-09-27 13:14:02 +0200 |
| commit | 5dfc14d359e1a2fae85154a41b109b129a647449 (patch) | |
| tree | 99c65e1acb560af86d3d08c27f563dff583ffbc2 /addons/web/static/src/js/boot.js | |
| parent | 8b2f8e1c88b339bb25c089c1623ca1f8b796237c (diff) | |
| parent | 6b8d98b54a4025c1d4c58d8f2d1c809fb5192909 (diff) | |
[IMP] web_preload js part
bzr revid: al@openerp.com-20110927111402-teb8bpavj4atghle
Diffstat (limited to 'addons/web/static/src/js/boot.js')
| -rw-r--r-- | addons/web/static/src/js/boot.js | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/addons/web/static/src/js/boot.js b/addons/web/static/src/js/boot.js index 10c8de096b2..f41185be0c6 100644 --- a/addons/web/static/src/js/boot.js +++ b/addons/web/static/src/js/boot.js @@ -19,9 +19,9 @@ /** * OpenERP instance constructor * - * @param {Boolean} skip_init if true, skips the built-in initialization + * @param {Array} modules list of modules to initialize */ - init: function(skip_init) { + init: function(modules) { var new_instance = { // links to the global openerp _openerp: openerp, @@ -35,8 +35,9 @@ web_mobile: {} }; openerp.sessions[new_instance._session_id] = new_instance; - if (!skip_init){ - openerp.web(new_instance); + modules = modules || ["web"]; + for(var i=0; i < modules.length; i++) { + openerp[modules[i]](new_instance); } return new_instance; } |
