[Erp5-report] r43459 ivan - in /erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style: SkinTe...

nobody at svn.erp5.org nobody at svn.erp5.org
Fri Feb 18 09:55:58 CET 2011


Author: ivan
Date: Fri Feb 18 09:55:58 2011
New Revision: 43459

URL: http://svn.erp5.org?rev=43459&view=rev
Log:
Gadget listboxes will have an unique field_prefix which will guaranteed that multiple gadgets and multiple asynchronous gadgets can safely co exists in same DOM space within same HTML form without collisions.

Modified:
    erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTML.xml
    erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml
    erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTML.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTML.xml?rev=43459&r1=43458&r2=43459&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTML.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTML.xml [utf8] Fri Feb 18 09:55:58 2011
@@ -79,7 +79,8 @@
               show_list_action_link python: here.field.get_value(\'list_action\');\n
               page_navigation_template python: request.get(\'page_navigation_template\', here.getPageNavigationTemplate());\n
               is_slider_mode python:  \'Slider\' in page_navigation_template;\n
-              is_default_listbox_field python: field_id==\'listbox\';">\n
+              is_default_listbox_field python: field_id==\'listbox\';\n
+              field_prefix python: \'\';">\n
 \n
   <!-- Define hidden input.  -->\n
   <input type="hidden" \n
@@ -111,7 +112,8 @@
     <tal:block tal:define="global box_relative_url python: request.get(\'box_relative_url\', \'\');\n
                            global box python: real_context.restrictedTraverse(box_relative_url); \n
                            global box_id python: \'%s_content\' %box_relative_url.replace(\'/\', \'_\');\n
-                           global dom_id python: request.get(\'dom_id\',None) or box_id;">\n
+                           global dom_id python: request.get(\'dom_id\',None) or box_id;\n
+                           global field_prefix string:${box_id}_">\n
       <input tal:condition="python:form_id" \n
              type="hidden" \n
              name="gadget_form_id"\n
@@ -467,10 +469,10 @@
                   <tal:block tal:repeat="value render_result">\n
                     <td class="listbox-table-data-cell"\n
                         tal:define="html  python: value[0];">\n
-                      <input tal:condition="not: repeat/value/index"\n
-                             type="hidden" value="1" name="listbox_uid:list"\n
-                             tal:attributes="value python: line.getUid() or \'\';\n
-                                             name string:${field_id}_uid:list" />\n
+                        <input tal:condition="not: repeat/value/index"\n
+                               type="hidden" value="1" name="listbox_uid:list"\n
+                               tal:attributes="value python: line.getUid() or \'\';\n
+                                               name string:${field_prefix}${field_id}_uid:list" />\n
                       <tal:block tal:replace="structure html"/>\n
                     </td>\n
                   </tal:block>\n
@@ -533,9 +535,7 @@
   </div>\n
 </div>\n
 \n
-</tal:block>\n
-\n
-
+</tal:block>
 
 ]]></unicode> </value>
         </item>
@@ -553,7 +553,7 @@
         </item>
         <item>
             <key> <string>output_encoding</string> </key>
-            <value> <string>utf-8</string> </value>
+            <value> <string>iso-8859-15</string> </value>
         </item>
         <item>
             <key> <string>title</string> </key>

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml?rev=43459&r1=43458&r2=43459&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/SkinTemplateItem/portal_skins/erp5_xhtml_style/ListBox_asHTMLLibrary.xml [utf8] Fri Feb 18 09:55:58 2011
@@ -250,7 +250,7 @@
                  class = "listbox_first_page"\n
                  tal:attributes="value string:|&lt;;\n
                                  onclick python:\n
-                                 real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params);\n
+                                 real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params, field_prefix=field_prefix);\n
                                  class python: test(is_default_listbox_field, \'listbox_first_page\', \'listbox_first_page %s_first_page\' %field_id)"\n
                  i18n:domain="ui" i18n:attributes="title">\n
             <span class="image"/>\n
@@ -261,7 +261,7 @@
                   type="button"\n
                   class="listbox_previous_page"\n
                   tal:attributes="value string:&lt;&lt;;\n
-                                  onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params);\n
+                                  onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params,field_prefix=field_prefix);\n
                                   class python: test(is_default_listbox_field, \'listbox_previous_page\', \'listbox_previous_page %s_previous_page\' %field_id)"\n
                   i18n:domain="ui" i18n:attributes="title">\n
             <span class="image"/>\n
@@ -279,7 +279,7 @@
               name="nextPage"\n
               type="button"\n
               class="listbox_next_page"\n
-              tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params);\n
+              tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params,field_prefix=field_prefix);\n
                               class python: test(is_default_listbox_field, \'listbox_next_page\', \'listbox_next_page %s_next_page\' %field_id)"\n
               i18n:domain="ui" i18n:attributes="title">\n
             <span class="image"/>\n
@@ -289,7 +289,7 @@
                name="lastPage"\n
                type="button"\n
                class="listbox_last_page"\n
-               tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params);\n
+               tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params,field_prefix=field_prefix);\n
                                class python: test(is_default_listbox_field, \'listbox_last_page\', \'listbox_last_page %s_last_page\' %field_id)"\n
                i18n:domain="ui" i18n:attributes="title">\n
             <span class="image"/>\n
@@ -320,7 +320,7 @@
                            class python: test(is_default_listbox_field, "listbox_set_page", "listbox_set_page %s_set_page" %field_id);\n
                            value python:here.current_page + 1;\n
                            size python:len(str(here.total_pages));\n
-                           onkeypress python:"if(event.keyCode==13){" + real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params).replace("\\"this.value\\"","this.value")+ "return false;;}"\'/>\n
+                           onkeypress python:"if(event.keyCode==13){" + real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params,field_prefix=field_prefix).replace("\\"this.value\\"","this.value")+ "return false;;}"\'/>\n
     / <tal:block content="here/total_pages" />\n
   </tal:block>\n
 \n
@@ -338,7 +338,7 @@
   <tal:block metal:define-macro="text_link_page_navigation_asynchronous">\n
     <tal:block tal:repeat="page_index page_index_list ">\n
       <a tal:define="params python: {field_id+\'_setPage:method\':\'\',field_id+\'_page_start\':page_index,\'list_style\':list_style, \'list_selection_name\':selection_name, \'listbox_uid\':[]}"\n
-         tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params);\n
+         tal:attributes="onclick python: real_context.KnowledgePad_generateAjaxCall(context_url,box,dom_id,params,field_prefix=field_prefix);\n
                          class python: test(page_index==current_page, \'selected\', \'\');\n
                          title string:Page ${page_index}"\n
          tal:content="page_index"/>\n

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision?rev=43459&r1=43458&r2=43459&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_xhtml_style/bt/revision [utf8] Fri Feb 18 09:55:58 2011
@@ -1 +1 @@
-1063
\ No newline at end of file
+1064
\ No newline at end of file



More information about the Erp5-report mailing list