From 18cc6542b63110ec2f63a5c2af14e903c14d5f28 Mon Sep 17 00:00:00 2001 From: niv-openerp Date: Thu, 4 Oct 2012 17:34:00 +0200 Subject: [PATCH] Renammed get_field to get_field_desc bzr revid: nicolas.vanhoren@openerp.com-20121004153400-odaxckppdi1od6mw --- addons/web/static/src/js/view_form.js | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/addons/web/static/src/js/view_form.js b/addons/web/static/src/js/view_form.js index 58046fb9ff6..f5e701a5dce 100644 --- a/addons/web/static/src/js/view_form.js +++ b/addons/web/static/src/js/view_form.js @@ -30,7 +30,7 @@ instance.web.form.FieldManagerMixin = { /** * Must return the asked field as in fields_get. */ - get_field: function(field_name) {}, + get_field_desc: function(field_name) {}, /** * Returns the current value of a field present in the view. See the get_value() method * method in FieldInterface for further information. @@ -1100,7 +1100,7 @@ instance.web.FormView = instance.web.View.extend(instance.web.form.FieldManagerM field.on('focused', null, this.proxy('widgetFocused')) .on('blurred', null, this.proxy('widgetBlurred')); - if (this.get_field(name).translate) { + if (this.get_field_desc(name).translate) { this.translatable_fields.push(field); } field.on('changed_value', this, function() { @@ -1118,7 +1118,7 @@ instance.web.FormView = instance.web.View.extend(instance.web.form.FieldManagerM } }); }, - get_field: function(field_name) { + get_field_desc: function(field_name) { return this.fields_view.fields[field_name]; }, get_field_value: function(field_name) { @@ -2017,7 +2017,7 @@ instance.web.form.AbstractField = instance.web.form.FormWidget.extend(instance.w var self = this this._super(field_manager, node); this.name = this.node.attrs.name; - this.field = this.field_manager.get_field(this.name); + this.field = this.field_manager.get_field_desc(this.name); this.widget = this.node.attrs.widget; this.string = this.node.attrs.string || this.field.string || this.name; this.options = JSON.parse(this.node.attrs.options || '{}'); @@ -4630,7 +4630,7 @@ instance.web.form.FieldReference = instance.web.form.AbstractField.extend(instan get_field: function(name) { if (name === "selection") { return { - selection: this.field_manager.get_field(this.name).selection, + selection: this.field_manager.get_field_desc(this.name).selection, type: "selection", }; } else if (name === "m2o") {