summaryrefslogtreecommitdiff
path: root/addons/web/static/src/js/coresetup.js
diff options
context:
space:
mode:
authorniv-openerp <nicolas.vanhoren@openerp.com>2013-07-15 14:16:11 +0200
committerniv-openerp <nicolas.vanhoren@openerp.com>2013-07-15 14:16:11 +0200
commit7743f13c0409195a3270ff516ccfc27db20dd2a9 (patch)
treed3de9e0a56602ec1c2d31dce67308cae2a301183 /addons/web/static/src/js/coresetup.js
parenta81df9ca2b9cd8536d51b1d8b0a4be104b997244 (diff)
[FIX] small bug that made the reports crash when we try to print them
bzr revid: nicolas.vanhoren@openerp.com-20130715121611-q68m7w62h8ngnb2i
Diffstat (limited to 'addons/web/static/src/js/coresetup.js')
-rw-r--r--addons/web/static/src/js/coresetup.js7
1 files changed, 4 insertions, 3 deletions
diff --git a/addons/web/static/src/js/coresetup.js b/addons/web/static/src/js/coresetup.js
index 3ba5855533f..c9c6f82a98d 100644
--- a/addons/web/static/src/js/coresetup.js
+++ b/addons/web/static/src/js/coresetup.js
@@ -334,9 +334,10 @@ instance.web.Session = instance.web.JsonRPC.extend( /** @lends instance.web.Sess
}).appendTo(document.body);
}
- _(_.extend({}, options.data || {},
- {session_id: this.override_session ? this.session_id : undefined, token: token}))
- .each(function (value, key) {
+ var hparams = _.extend({}, options.data || {}, {token: token});
+ if (this.override_session)
+ hparams.session_id = this.session_id;
+ _.each(hparams, function (value, key) {
var $input = $form.find('[name=' + key +']');
if (!$input.length) {
$input = $('<input type="hidden" name="' + key + '">')