From 136292f6890ff730b5a9fd70eb503d4f6a0f9c4a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?G=C3=A9ry=20Debongnie?= Date: Thu, 23 Feb 2017 10:36:13 +0100 Subject: [REF] web, *: move CompoundContext out of data.js We want to remove data.js, but we still need the CompoundContext class, so we take it out, and rename it 'Context' --- addons/web/static/src/js/fields/relational_fields.js | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'addons/web/static/src/js/fields/relational_fields.js') diff --git a/addons/web/static/src/js/fields/relational_fields.js b/addons/web/static/src/js/fields/relational_fields.js index 4282d78faf7..25c96a76a80 100644 --- a/addons/web/static/src/js/fields/relational_fields.js +++ b/addons/web/static/src/js/fields/relational_fields.js @@ -16,6 +16,7 @@ odoo.define('web.relational_fields', function (require) { var AbstractField = require('web.AbstractField'); var concurrency = require('web.concurrency'); var config = require('web.config'); +var Context = require('web.Context'); var ControlPanel = require('web.ControlPanel'); var dialogs = require('web.view_dialogs'); var core = require('web.core'); @@ -376,7 +377,7 @@ var FieldMany2One = AbstractRelationalField.extend(mixins.ServicesMixin, { new dialogs.SelectCreateDialog(this, _.extend({}, this.nodeOptions, { res_model: this.field.relation, domain: data.build_domain(this.record, this.domain), - context: new data.CompoundContext(data.build_context(this.record, this.context), context || {}), + context: new Context(data.build_context(this.record, this.context), context || {}), title: (view === 'search' ? _t("Search: ") : _t("Create: ")) + this.string, initial_ids: ids ? _.map(ids, function (x) { return x[0]; }) : undefined, initial_view: view, -- cgit v1.2.3