[fix] problem with email template preview
[odoo/odoo.git] / addons / web / static / src / js / view_form.js
index 5f2f587..fe604a8 100644 (file)
@@ -257,7 +257,7 @@ openerp.web.FormView = openerp.web.View.extend( /** @lends openerp.web.FormView#
             'None': function () {return null;},
             'context': function (i) {
                 context_index = i;
-                var ctx = widget.build_context ? widget.build_context() : {};
+                var ctx = new openerp.web.CompoundContext(self.dataset.get_context(), widget.build_context() ? widget.build_context() : {});
                 return ctx;
             }
         };