Test if any column has width before saving it

otherwise list is hidden and there is no width

review48004
This commit is contained in:
Cédric Krier committed 2011-07-20 21:54:36 +02:00
1 parent dce43d355d
commit 1ed66bf3c8
1 file changed
+1 -1
+1 -1
View File
@@ -634,7 +634,7 @@ class ViewList(ParserView):
if last_col and last_col.name in fields:
del fields[last_col.name]
if fields:
if fields and any(fields.itervalues()):
try:
rpc.execute('model', 'ir.ui.view_tree_width', 'set_width',
self.screen.model_name, fields, rpc.CONTEXT)