[Erp5-report] r36033 jerome - in /erp5/trunk/products/ERP5/bootstrap/erp5_core: SkinTemplat...

nobody at svn.erp5.org nobody at svn.erp5.org
Mon Jun 7 16:58:36 CEST 2010


Author: jerome
Date: Mon Jun  7 16:58:33 2010
New Revision: 36033

URL: http://svn.erp5.org?rev=36033&view=rev
Log:
Don't do too much in Base_callDialogMethod when using "update" button: don't switch to deferred more in update, and don't change the skin manually when the URL is too big to redirect.

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=36033&r1=36032&r2=36033&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Base_callDialogMethod.xml [utf8] Mon Jun  7 16:58:33 2010
@@ -236,8 +236,8 @@
   if v not in (None, [], ()) :\n
     clean_kw[k] = kw[k]\n
 \n
-# Handle deferred style\n
-if clean_kw.get(\'deferred_style\', 0):\n
+# Handle deferred style, unless we are executing the update action\n
+if dialog_method != update_method and clean_kw.get(\'deferred_style\', 0):\n
   clean_kw[\'deferred_portal_skin\'] = clean_kw.get(\'portal_skin\', None)\n
   # XXX Hardcoded Deferred style name\n
   clean_kw[\'portal_skin\'] = \'Deferred\'\n
@@ -259,7 +259,8 @@
 # If url is too long, we do not redirect to avoid crash.\n
 # XXX: 2000 is an arbitrary value resulted from trial and error.\n
 if (not(can_redirect) or len(url_params_string) > 2000):\n
-  if \'portal_skin\' in clean_kw:\n
+  # change the skin, unless we are executing the update action\n
+  if dialog_method != update_method and \'portal_skin\' in clean_kw:\n
     new_skin_name = clean_kw[\'portal_skin\']\n
     context.getPortalObject().portal_skins.changeSkin(new_skin_name)\n
     request.set(\'portal_skin\', new_skin_name)\n
@@ -308,7 +309,7 @@
         </item>
         <item>
             <key> <string>_params</string> </key>
-            <value> <string>dialog_method, dialog_id, dialog_category=\'\', **kw</string> </value>
+            <value> <string>dialog_method, dialog_id, dialog_category=\'\', update_method=None, **kw</string> </value>
         </item>
         <item>
             <key> <string>errors</string> </key>
@@ -328,7 +329,7 @@
                   <dictionary>
                     <item>
                         <key> <string>co_argcount</string> </key>
-                        <value> <int>3</int> </value>
+                        <value> <int>4</int> </value>
                     </item>
                     <item>
                         <key> <string>co_varnames</string> </key>
@@ -337,6 +338,7 @@
                             <string>dialog_method</string>
                             <string>dialog_id</string>
                             <string>dialog_category</string>
+                            <string>update_method</string>
                             <string>kw</string>
                             <string>Products.ERP5Type.Log</string>
                             <string>log</string>
@@ -406,6 +408,7 @@
             <value>
               <tuple>
                 <string></string>
+                <none/>
               </tuple>
             </value>
         </item>

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=36033&r1=36032&r2=36033&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] Mon Jun  7 16:58:33 2010
@@ -1,1 +1,1 @@
-1599
+1600




More information about the Erp5-report mailing list