← Back to team overview

c2c-oerpscenario team mailing list archive

[Bug 722766] Re: [6.0] bad _rec_name in default tree view creation

 

** Changed in: openobject-server
   Importance: Undecided => Low

** Changed in: openobject-server
       Status: Incomplete => Confirmed

** Changed in: openobject-server
     Assignee: (unassigned) => OpenERP's Framework R&D (openerp-dev-framework)

** Tags added: optimization

-- 
You received this bug notification because you are a member of C2C
OERPScenario, which is subscribed to the OpenERP Project Group.
https://bugs.launchpad.net/bugs/722766

Title:
  [6.0] bad _rec_name in default tree view creation

Status in OpenERP Server:
  Confirmed

Bug description:
  The default tree view is not using the right _rec_name:
  osv/orm.py : line 1622

  23             # otherwise, build some kind of default view
  (...)
  23             elif view_type == 'tree':
  23                 _rec_name = self._rec_name
  23                 if _rec_name not in self._columns:
  23                     _rec_name = self._columns.keys()[0]
  23                 xml = '<?xml version="1.0" encoding="utf-8"?>' \
  23                        '<tree string="%s"><field name="%s"/></tree>' \
  23                        % (self._description, self._rec_name)

  It should be the variable _rec_name set just before :
  23                        % (self._description, _rec_name)



References