[FIX] Fields : Only one2many fields can have relation_field,avoid checks for others

lp bug: https://launchpad.net/bugs/519468 fixed

bzr revid: jvo@tinyerp.com-20100210054537-yhfenk6z6tlm9nzt
This commit is contained in:
Jay (Open ERP)
2010-02-10 11:15:37 +05:30
parent ebbaab4139
commit 372673aeba
+1 -1
View File
@@ -380,7 +380,7 @@ class orm_template(object):
'select_level': tools.ustr(f.select or 0),
'readonly':(f.readonly and 1) or 0,
'required':(f.required and 1) or 0,
'relation_field': f._type=='one2many' and f._fields_id or '',
'relation_field': (f._type=='one2many' and isinstance(f,fields.one2many)) and f._fields_id or '',
}
# When its a custom field,it does not contain f.select
if context.get('field_state','base') == 'manual':