[Erp5-report] r15469 - /erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/porta...

nobody at svn.erp5.org nobody at svn.erp5.org
Fri Aug 3 17:38:11 CEST 2007


Author: yusei
Date: Fri Aug  3 17:38:11 2007
New Revision: 15469

URL: http://svn.erp5.org?rev=15469&view=rev
Log:
2007-08-03 yusei
Remove obsolute code from Base_doSelect.

Modified:
    erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_doSelect.xml

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_doSelect.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_doSelect.xml?rev=15469&r1=15468&r2=15469&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_doSelect.xml (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_doSelect.xml Fri Aug  3 17:38:11 2007
@@ -69,50 +69,20 @@
         <item>
             <key> <string>_body</string> </key>
             <value> <string>from ZTUtils import make_query\n
-from ZODB.POSException import ConflictError\n
 \n
 request = context.REQUEST\n
 \n
 #return request\n
 \n
-if list_method_id:\n
-  kw = { \'selection_index\': selection_index,\n
-         \'selection_name\': selection_name,\n
-         \'list_method_id\': list_method_id,\n
-        }\n
-else:\n
-  kw = { \'selection_index\': selection_index,\n
-         \'selection_name\': selection_name,\n
-        }\n
+kw = { \'selection_index\': selection_index,\n
+       \'selection_name\': selection_name,\n
+      }\n
 \n
-if list_method_id:\n
-  try:\n
-    # Define form basic fields\n
-    form = getattr(context,form_id)\n
-    listbox_field = None\n
-    # Search listbox\n
-    for f in form.get_fields():\n
-      if f.meta_type == "ListBox":\n
-        listbox_field = f\n
-        break\n
-    # Lookup listbox Base_viewSearchResultList cols\n
-    for col_id, col_title in listbox_field.get_value(\'search_columns\'):\n
-      # Left is col_id\n
-      v = request.form.get(col_id, \'\')\n
-      kw[col_id] = v\n
-    # Redirect\n
-    request.RESPONSE.redirect(\'%s/%s?%s\' % (context.absolute_url(), form_id, make_query(kw)))\n
-  except ConflictError:\n
-    raise\n
-  except:\n
-    # Default behaviour is not as great but returns something\n
-    return getattr(context,form_id)(request)\n
-else:\n
-  # Default behaviour is not as great but returns something\n
-  kw.update(request.form)\n
-  if kw.has_key(\'listbox_uid\'): del kw[\'listbox_uid\']\n
-  if kw.has_key(\'list_start\'): del kw[\'list_start\']\n
-  request.RESPONSE.redirect(\'%s/%s?%s\' % (context.absolute_url(), form_id, make_query(kw)))\n
+# Default behaviour is not as great but returns something\n
+kw.update(request.form)\n
+if kw.has_key(\'listbox_uid\'): del kw[\'listbox_uid\']\n
+if kw.has_key(\'list_start\'): del kw[\'list_start\']\n
+request.RESPONSE.redirect(\'%s/%s?%s\' % (context.absolute_url(), form_id, make_query(kw)))\n
 </string> </value>
         </item>
         <item>
@@ -129,7 +99,7 @@
         </item>
         <item>
             <key> <string>_params</string> </key>
-            <value> <string>form_id=\'\', selection_index=\'\', selection_name=\'\', list_method_id=None</string> </value>
+            <value> <string>form_id=\'\', selection_index=\'\', selection_name=\'\'</string> </value>
         </item>
         <item>
             <key> <string>errors</string> </key>
@@ -149,7 +119,7 @@
                   <dictionary>
                     <item>
                         <key> <string>co_argcount</string> </key>
-                        <value> <int>4</int> </value>
+                        <value> <int>3</int> </value>
                     </item>
                     <item>
                         <key> <string>co_varnames</string> </key>
@@ -158,24 +128,12 @@
                             <string>form_id</string>
                             <string>selection_index</string>
                             <string>selection_name</string>
-                            <string>list_method_id</string>
                             <string>ZTUtils</string>
                             <string>make_query</string>
-                            <string>ZODB.POSException</string>
-                            <string>ConflictError</string>
                             <string>_getattr_</string>
                             <string>context</string>
                             <string>request</string>
                             <string>kw</string>
-                            <string>getattr</string>
-                            <string>form</string>
-                            <string>None</string>
-                            <string>listbox_field</string>
-                            <string>_getiter_</string>
-                            <string>f</string>
-                            <string>col_id</string>
-                            <string>col_title</string>
-                            <string>v</string>
                             <string>_write_</string>
                           </tuple>
                         </value>
@@ -192,7 +150,6 @@
                 <string></string>
                 <string></string>
                 <string></string>
-                <none/>
               </tuple>
             </value>
         </item>




More information about the Erp5-report mailing list