~openerp-dev/openobject-client-web/trunk-bug-733089-jra

« back to all changes in this revision

Viewing changes to addons/openerp/static/javascript/m2o.js

  • Committer: Xavier Morel
  • Date: 2011-03-11 16:22:33 UTC
  • mfrom: (4454.1.77 6.0)
  • Revision ID: xmo@openerp.com-20110311162233-pr8f9twsfne7pgnt
[FIX] opening m2o records in readonly view from 6.0

Show diffs side-by-side

added added

removed removed

Lines of Context:
183
183
 * value of the m2o
184
184
 */
185
185
ManyToOne.prototype.get_context = function () {
 
186
    if(!this.text) {
 
187
        return jQuery(this.field).attr('context');
 
188
    }
186
189
    return jQuery(this.field).attr('context').replace(
187
190
            /\bself\b/g, "'" + this.text.value + "'");
188
191
};