[Erp5-report] r16015 - in /erp5/trunk/products/ERP5/bootstrap/erp5_core: SkinTemplateItem/p...

nobody at svn.erp5.org nobody at svn.erp5.org
Mon Sep 3 13:55:28 CEST 2007


Author: seb
Date: Mon Sep  3 13:55:27 2007
New Revision: 16015

URL: http://svn.erp5.org?rev=16015&view=rev
Log:
It's not a good idea to put the content of the listbox inside the pickle on dialogs. The content of listbox is too big in order to fit into pickle, and we exceed the url size limit. This should not break dialogs and fast inputs.

Modified:
    erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml
    erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml?rev=16015&r1=16014&r2=16015&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml Mon Sep  3 13:55:27 2007
@@ -3,11 +3,8 @@
   <record id="1" aka="AAAAAAAAAAE=">
     <pickle>
       <tuple>
-        <tuple>
-          <string>Products.PythonScripts.PythonScript</string>
-          <string>PythonScript</string>
-        </tuple>
-        <none/>
+        <global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
+        <tuple/>
       </tuple>
     </pickle>
     <pickle>
@@ -216,7 +213,15 @@
     kw[listbox_id] = request_form[listbox_id] = listbox_line_list\n
 \n
 if enable_pickle or (form.update_action != \'\'):\n
-  kw[\'pickle_string\'] = request_form[\'pickle_string\'] = context.portal_selections.getPickle(**kw)\n
+  # Do not put listbox in pickle, because this pickle becomes too big\n
+  # wich is not compatible with the url limit size\n
+  pickle_kw = {}\n
+  excluded_key_list = listbox_id_list\n
+  excluded_key_list.extend(["%s_uid" % x for x in listbox_id_list])\n
+  for key in kw.keys():\n
+    if key not in excluded_key_list:\n
+      pickle_kw[key] = kw[key]\n
+  kw[\'pickle_string\'] = request_form[\'pickle_string\'] = context.portal_selections.getPickle(**pickle_kw)\n
 \n
 # Check if the selection changed\n
 if hasattr(kw, \'previous_md5_object_uid_list\'):\n
@@ -370,6 +375,11 @@
                             <string>key</string>
                             <string>listbox_line</string>
                             <string>tuple</string>
+                            <string>pickle_kw</string>
+                            <string>excluded_key_list</string>
+                            <string>append</string>
+                            <string>$append0</string>
+                            <string>x</string>
                             <string>selection_list</string>
                             <string>map</string>
                             <string>object_uid_list</string>

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision?rev=16015&r1=16014&r2=16015&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision Mon Sep  3 13:55:27 2007
@@ -1,1 +1,1 @@
-424
+425




More information about the Erp5-report mailing list