[Erp5-report] r26588 - /erp5/trunk/products/ERP5Form/ListBox.py

nobody at svn.erp5.org nobody at svn.erp5.org
Wed Apr 22 15:04:27 CEST 2009


Author: jerome
Date: Wed Apr 22 15:04:25 2009
New Revision: 26588

URL: http://svn.erp5.org?rev=26588&view=rev
Log:
use getEditableField method to get an editable field, this method supports
proxy fields (it looks in the target form to find fields if not found in
current form)

Modified:
    erp5/trunk/products/ERP5Form/ListBox.py

Modified: erp5/trunk/products/ERP5Form/ListBox.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5Form/ListBox.py?rev=26588&r1=26587&r2=26588&view=diff
==============================================================================
--- erp5/trunk/products/ERP5Form/ListBox.py [utf8] (original)
+++ erp5/trunk/products/ERP5Form/ListBox.py [utf8] Wed Apr 22 15:04:25 2009
@@ -990,13 +990,10 @@
         if search_field is None:
           search_alias = '_'.join(search_id.split('.'))
           # If the search field could not be found, try to get an "editable" field on current form.
-          editable_field_id = '%s_%s' % (listbox_id, search_alias)
-          if listbox_form.has_field(editable_field_id, include_disabled=1): # We must include disabled fields at this
-                                                                            # stage since there is no way (yet)
-                                                                            # to evalue cell in TALES expressions
-            search_field = listbox_form.get_field(editable_field_id, include_disabled=1)
-          else:
+          search_field = self.getEditableField(search_alias)
+          if search_field is None:
             continue
+
         render_dict = search_field.render_dict(search_value)
         if render_dict is not None:
           params[search_id] = render_dict




More information about the Erp5-report mailing list