fix web2py/web2py#896, avoid to select blob fields in sqlform.grid

This commit is contained in:
ilvalle
2015-04-02 21:38:05 +02:00
parent 6b6cb5839c
commit 60f8816a10
+1 -1
View File
@@ -2148,7 +2148,7 @@ class SQLFORM(FORM):
else: else:
fields = [] fields = []
columns = [] columns = []
filter1 = lambda f: isinstance(f, Field) filter1 = lambda f: isinstance(f, Field) and f.type != 'blob'
filter2 = lambda f: isinstance(f, Field) and f.readable filter2 = lambda f: isinstance(f, Field) and f.readable
for table in tables: for table in tables:
fields += filter(filter1, table) fields += filter(filter1, table)