Commit 8cb83f48 authored by Christophe Dumez's avatar Christophe Dumez

- Fixed 2 bugs in Listbox, one concerning unicode support and another...

- Fixed 2 bugs in Listbox, one concerning unicode support and another concerning a file instance in the REQUEST that couldn't be pickled


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@9063 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 601c91cd
......@@ -926,7 +926,7 @@ class ListBoxRenderer:
# Remove useless parameters.
for k, v in params.items():
if v in (None, ''):
if v in (None, '') or hasattr(v, 'read'):
del params[k]
# Set the columns. The idea behind this is that, instead of selecting all columns,
......@@ -1841,7 +1841,7 @@ class ListBoxRendererLine:
# Process the value.
if processed_value is None:
processed_value = u''
else:
elif not isinstance(processed_value, unicode):
processed_value = unicode(str(processed_value), self.renderer.getEncoding())
value_list.append((original_value, processed_value))
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment