Ignore Fields that starts with "_"

This commit is contained in:
Cédric Krier
2010-01-16 14:24:26 +01:00
parent 533968078a
commit 8112d78bdd
2 changed files with 2 additions and 1 deletions
+1
View File
@@ -1,3 +1,4 @@
* Ignore Fields that starts with "_"
* Add comment on table and field for postgresql backend
* Remove egenix-mx-base and replace it by python-dateutil
* Add cache to safe_eval
+1 -1
View File
@@ -37,7 +37,7 @@ class Model(object):
return self.__columns
res = {}
for attr in dir(self):
if attr in ('_columns', '_defaults', '_xxx2many_targets'):
if attr.startswith('_'):
continue
if isinstance(getattr(self, attr), fields.Field):
res[attr] = getattr(self, attr)