diff --git a/bin/osv/fields.py b/bin/osv/fields.py index dbcc30822b7..4ae70fd33e7 100644 --- a/bin/osv/fields.py +++ b/bin/osv/fields.py @@ -525,14 +525,14 @@ class property(function): return res def _field_get(self, self2, cr, uid, prop): - if not self.field_id: + if not self.field_id.get(cr.dbname): cr.execute('select id from ir_model_fields where name=%s and model=%s', (prop, self2._name)) res = cr.fetchone() - self.field_id = res and res[0] - return self.field_id + self.field_id[cr.dbname] = res and res[0] + return self.field_id[cr.dbname] def __init__(self, obj_prop, **args): - self.field_id = False + self.field_id = {} function.__init__(self, self._fnct_read, False, self._fnct_write, (obj_prop, ), diff --git a/doc/INSTALL b/doc/INSTALL index eea1f651435..a1814d26203 100644 --- a/doc/INSTALL +++ b/doc/INSTALL @@ -33,6 +33,14 @@ following commands: apt-get install libxslt1-python2.3 python2.3-psycopg python2.3-reportlab apt-get install python2.3-imaging python2.3-pyparsing graphviz +For newer Debian-based distributions such as Etch, the required packages can be +installed with the following commands: + + apt-get install python2.4 python-xml postgresql postgresql-client python-libxml2 + apt-get install python-libxslt1 python-psycopg python-reportlab + apt-get install python-imaging python-pyparsing graphviz + + For Fedora if they are not installed, install: python and postgresql