[Erp5-report] r40761 nicolas - /erp5/trunk/products/ERP5Form/MultiRelationField.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Nov 26 11:00:19 CET 2010
Author: nicolas
Date: Fri Nov 26 11:00:09 2010
New Revision: 40761
URL: http://svn.erp5.org?rev=40761&view=rev
Log:
delete unnecessary condition
Modified:
erp5/trunk/products/ERP5Form/MultiRelationField.py
Modified: erp5/trunk/products/ERP5Form/MultiRelationField.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Form/MultiRelationField.py?rev=40761&r1=40760&r2=40761&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Form/MultiRelationField.py [utf8] (original)
+++ erp5/trunk/products/ERP5Form/MultiRelationField.py [utf8] Fri Nov 26 11:00:09 2010
@@ -318,11 +318,10 @@ class MultiRelationStringFieldWidget(Wid
kw[k] = v
accessor_name = 'get%sValueList' % ''.join([part.capitalize() for part in base_category.split('_')])
jump_reference_list = getattr(here, accessor_name)(portal_type=portal_type, filter=kw)
- if len(jump_reference_list):
- for jump_reference in jump_reference_list:
- string_list.append('<a href="%s">%s</a>' % \
- (jump_reference.absolute_url(),
- jump_reference.getTitle()))
+ for jump_reference in jump_reference_list:
+ string_list.append('<a href="%s">%s</a>' % \
+ (jump_reference.absolute_url(),
+ jump_reference.getTitle()))
html_string = '<br />'.join(string_list)
else:
html_string = self.default_widget_rendering_instance.render_view(field,
More information about the Erp5-report
mailing list