[FIX] assertion message

bzr revid: al@openerp.com-20120731122557-9ka14pw09x2fhmos
This commit is contained in:
Antony Lesuisse 2012-07-31 14:25:57 +02:00
parent d375ee272e
commit 8540dcf017
1 changed files with 1 additions and 1 deletions

View File

@ -1056,7 +1056,7 @@ class BaseModel(object):
# Validate rec_name
if self._rec_name:
assert self._rec_name in self._columns
assert self._rec_name in self._columns.keys() + ['id'], "Invalid rec_name %s for model %s" % (self.rec_name, self._name)
else:
self._rec_name = 'name'