From c4f9af5bd7013b6a7fb303b46c3dcf4e9705e8fa Mon Sep 17 00:00:00 2001
From: Kazuhiko Shiozaki <kazuhiko@nexedi.com>
Date: Thu, 30 Apr 2009 14:21:13 +0000
Subject: [PATCH] * add 'Contents' tab in WebSite view. * remove needless
 WebSection_viewContentList.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@26748 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../Web%20Site/local_permission.xml           |   2 +-
 .../section_content.xml}                      |  10 +-
 .../WebSection_viewContent/listbox.xml        |   7 +-
 .../erp5_web/WebSection_viewContentList.xml   | 115 --------
 .../WebSection_viewContentList/listbox.xml    | 248 ------------------
 .../listbox_creation_date.xml                 | 109 --------
 .../listbox_modification_date.xml             | 109 --------
 bt5/erp5_web/bt/template_action_path_list     |   2 +-
 8 files changed, 13 insertions(+), 589 deletions(-)
 rename bt5/erp5_web/ActionTemplateItem/portal_types/{Web%20Section/list.xml => Web%20Site/section_content.xml} (88%)
 delete mode 100644 bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList.xml
 delete mode 100644 bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox.xml
 delete mode 100644 bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_creation_date.xml
 delete mode 100644 bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_modification_date.xml

diff --git a/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/local_permission.xml b/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/local_permission.xml
index d3c13aa2c8..e43e5974a0 100644
--- a/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/local_permission.xml
+++ b/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/local_permission.xml
@@ -47,7 +47,7 @@
         </item>
         <item>
             <key> <string>priority</string> </key>
-            <value> <float>5.0</float> </value>
+            <value> <float>7.0</float> </value>
         </item>
         <item>
             <key> <string>title</string> </key>
diff --git a/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Section/list.xml b/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/section_content.xml
similarity index 88%
rename from bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Section/list.xml
rename to bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/section_content.xml
index eaf278de7b..8e1a026812 100644
--- a/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Section/list.xml
+++ b/bt5/erp5_web/ActionTemplateItem/portal_types/Web%20Site/section_content.xml
@@ -17,7 +17,7 @@
         </item>
         <item>
             <key> <string>category</string> </key>
-            <value> <string>object_list</string> </value>
+            <value> <string>object_view</string> </value>
         </item>
         <item>
             <key> <string>condition</string> </key>
@@ -33,7 +33,7 @@
         </item>
         <item>
             <key> <string>id</string> </key>
-            <value> <string>list</string> </value>
+            <value> <string>section_content</string> </value>
         </item>
         <item>
             <key> <string>permissions</string> </key>
@@ -45,11 +45,11 @@
         </item>
         <item>
             <key> <string>priority</string> </key>
-            <value> <float>100.0</float> </value>
+            <value> <float>6.0</float> </value>
         </item>
         <item>
             <key> <string>title</string> </key>
-            <value> <string>List Content</string> </value>
+            <value> <string>Contents</string> </value>
         </item>
         <item>
             <key> <string>visible</string> </key>
@@ -69,7 +69,7 @@
       <dictionary>
         <item>
             <key> <string>text</string> </key>
-            <value> <string>string:${object_url}/WebSection_viewContentList</string> </value>
+            <value> <string>string:${object_url}/WebSection_viewContent</string> </value>
         </item>
       </dictionary>
     </pickle>
diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContent/listbox.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContent/listbox.xml
index 8fe923c14a..476c48a397 100644
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContent/listbox.xml
+++ b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContent/listbox.xml
@@ -23,6 +23,7 @@
                 <string>search</string>
                 <string>select</string>
                 <string>editable_columns</string>
+                <string>list_action</string>
               </list>
             </value>
         </item>
@@ -147,6 +148,10 @@
                     <key> <string>form_id</string> </key>
                     <value> <string>Base_viewFieldLibrary</string> </value>
                 </item>
+                <item>
+                    <key> <string>list_action</string> </key>
+                    <value> <string></string> </value>
+                </item>
                 <item>
                     <key> <string>list_method</string> </key>
                     <value>
@@ -197,7 +202,7 @@
                 </item>
                 <item>
                     <key> <string>title</string> </key>
-                    <value> <string>Section Content</string> </value>
+                    <value> <string>Section Contents</string> </value>
                 </item>
               </dictionary>
             </value>
diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList.xml
deleted file mode 100644
index b1998c7f84..0000000000
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList.xml
+++ /dev/null
@@ -1,115 +0,0 @@
-<?xml version="1.0"?>
-<ZopeData>
-  <record id="1" aka="AAAAAAAAAAE=">
-    <pickle>
-      <tuple>
-        <global name="ERP5Form" module="Products.ERP5Form.Form"/>
-        <tuple/>
-      </tuple>
-    </pickle>
-    <pickle>
-      <dictionary>
-        <item>
-            <key> <string>_bind_names</string> </key>
-            <value>
-              <object>
-                <klass>
-                  <global name="NameAssignments" module="Shared.DC.Scripts.Bindings"/>
-                </klass>
-                <tuple/>
-                <state>
-                  <dictionary>
-                    <item>
-                        <key> <string>_asgns</string> </key>
-                        <value>
-                          <dictionary/>
-                        </value>
-                    </item>
-                  </dictionary>
-                </state>
-              </object>
-            </value>
-        </item>
-        <item>
-            <key> <string>_objects</string> </key>
-            <value>
-              <tuple/>
-            </value>
-        </item>
-        <item>
-            <key> <string>action</string> </key>
-            <value> <string>Base_doSelect</string> </value>
-        </item>
-        <item>
-            <key> <string>encoding</string> </key>
-            <value> <string>UTF-8</string> </value>
-        </item>
-        <item>
-            <key> <string>enctype</string> </key>
-            <value> <string></string> </value>
-        </item>
-        <item>
-            <key> <string>group_list</string> </key>
-            <value>
-              <list>
-                <string>bottom</string>
-              </list>
-            </value>
-        </item>
-        <item>
-            <key> <string>groups</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>bottom</string> </key>
-                    <value>
-                      <list>
-                        <string>listbox</string>
-                        <string>listbox_creation_date</string>
-                        <string>listbox_modification_date</string>
-                      </list>
-                    </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>id</string> </key>
-            <value> <string>WebSection_viewContentList</string> </value>
-        </item>
-        <item>
-            <key> <string>method</string> </key>
-            <value> <string>POST</string> </value>
-        </item>
-        <item>
-            <key> <string>name</string> </key>
-            <value> <string>WebSection_viewContentList</string> </value>
-        </item>
-        <item>
-            <key> <string>pt</string> </key>
-            <value> <string>form_list</string> </value>
-        </item>
-        <item>
-            <key> <string>row_length</string> </key>
-            <value> <int>4</int> </value>
-        </item>
-        <item>
-            <key> <string>stored_encoding</string> </key>
-            <value> <string>UTF-8</string> </value>
-        </item>
-        <item>
-            <key> <string>title</string> </key>
-            <value> <string>Web Section</string> </value>
-        </item>
-        <item>
-            <key> <string>unicode_mode</string> </key>
-            <value> <int>0</int> </value>
-        </item>
-        <item>
-            <key> <string>update_action</string> </key>
-            <value> <string></string> </value>
-        </item>
-      </dictionary>
-    </pickle>
-  </record>
-</ZopeData>
diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox.xml
deleted file mode 100644
index 21723c4022..0000000000
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox.xml
+++ /dev/null
@@ -1,248 +0,0 @@
-<?xml version="1.0"?>
-<ZopeData>
-  <record id="1" aka="AAAAAAAAAAE=">
-    <pickle>
-      <tuple>
-        <global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
-        <tuple/>
-      </tuple>
-    </pickle>
-    <pickle>
-      <dictionary>
-        <item>
-            <key> <string>delegated_list</string> </key>
-            <value>
-              <list>
-                <string>title</string>
-                <string>lines</string>
-                <string>columns</string>
-                <string>sort</string>
-                <string>list_method</string>
-                <string>selection_name</string>
-                <string>portal_types</string>
-                <string>default_params</string>
-                <string>search</string>
-                <string>editable_columns</string>
-                <string>url_columns</string>
-              </list>
-            </value>
-        </item>
-        <item>
-            <key> <string>id</string> </key>
-            <value> <string>listbox</string> </value>
-        </item>
-        <item>
-            <key> <string>message_values</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>external_validator_failed</string> </key>
-                    <value> <string>The input failed the external validator.</string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>overrides</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string></string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>tales</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string></string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>values</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>columns</string> </key>
-                    <value>
-                      <list>
-                        <tuple>
-                          <string>reference</string>
-                          <string>Reference</string>
-                        </tuple>
-                        <tuple>
-                          <string>short_title</string>
-                          <string>Short Title</string>
-                        </tuple>
-                        <tuple>
-                          <string>translated_validation_state_title</string>
-                          <string>Validation State</string>
-                        </tuple>
-                        <tuple>
-                          <string>translated_portal_type</string>
-                          <string>Type</string>
-                        </tuple>
-                        <tuple>
-                          <string>creation_date</string>
-                          <string>Creation Date</string>
-                        </tuple>
-                        <tuple>
-                          <string>modification_date</string>
-                          <string>Modification Date</string>
-                        </tuple>
-                      </list>
-                    </value>
-                </item>
-                <item>
-                    <key> <string>default_params</string> </key>
-                    <value>
-                      <list/>
-                    </value>
-                </item>
-                <item>
-                    <key> <string>editable_columns</string> </key>
-                    <value>
-                      <list>
-                        <tuple>
-                          <string>creation_date</string>
-                          <string>Creation Date</string>
-                        </tuple>
-                        <tuple>
-                          <string>modification_date</string>
-                          <string>Modification</string>
-                        </tuple>
-                      </list>
-                    </value>
-                </item>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string>listbox</string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string>Category_viewFieldLibrary</string> </value>
-                </item>
-                <item>
-                    <key> <string>lines</string> </key>
-                    <value> <int>15</int> </value>
-                </item>
-                <item>
-                    <key> <string>list_method</string> </key>
-                    <value>
-                      <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
-                    </value>
-                </item>
-                <item>
-                    <key> <string>portal_types</string> </key>
-                    <value>
-                      <list>
-                        <tuple>
-                          <string>Web Page</string>
-                          <string>Web Page</string>
-                        </tuple>
-                        <tuple>
-                          <string>Web Section</string>
-                          <string>Web Section</string>
-                        </tuple>
-                      </list>
-                    </value>
-                </item>
-                <item>
-                    <key> <string>search</string> </key>
-                    <value> <int>1</int> </value>
-                </item>
-                <item>
-                    <key> <string>selection_name</string> </key>
-                    <value> <string>websection_content_selection</string> </value>
-                </item>
-                <item>
-                    <key> <string>sort</string> </key>
-                    <value>
-                      <list>
-                        <tuple>
-                          <string>short_title</string>
-                          <string>Short Title</string>
-                        </tuple>
-                      </list>
-                    </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string>Click to edit the target</string> </value>
-                </item>
-                <item>
-                    <key> <string>title</string> </key>
-                    <value> <string>Section Content</string> </value>
-                </item>
-                <item>
-                    <key> <string>url_columns</string> </key>
-                    <value>
-                      <list>
-                        <tuple>
-                          <string>short_title</string>
-                          <string>WebSite_getListboxUrl</string>
-                        </tuple>
-                        <tuple>
-                          <string>translated_validation_state_title</string>
-                          <string>WebSite_getListboxUrl</string>
-                        </tuple>
-                        <tuple>
-                          <string>translated_portal_type</string>
-                          <string>WebSite_getListboxUrl</string>
-                        </tuple>
-                        <tuple>
-                          <string>creation_date</string>
-                          <string>WebSite_getListboxUrl</string>
-                        </tuple>
-                        <tuple>
-                          <string>modification_date</string>
-                          <string>WebSite_getListboxUrl</string>
-                        </tuple>
-                      </list>
-                    </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-      </dictionary>
-    </pickle>
-  </record>
-  <record id="2" aka="AAAAAAAAAAI=">
-    <pickle>
-      <tuple>
-        <global name="Method" module="Products.Formulator.MethodField"/>
-        <tuple/>
-      </tuple>
-    </pickle>
-    <pickle>
-      <dictionary>
-        <item>
-            <key> <string>method_name</string> </key>
-            <value> <string>getDocumentValueList</string> </value>
-        </item>
-      </dictionary>
-    </pickle>
-  </record>
-</ZopeData>
diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_creation_date.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_creation_date.xml
deleted file mode 100644
index 08d5bdcfa5..0000000000
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_creation_date.xml
+++ /dev/null
@@ -1,109 +0,0 @@
-<?xml version="1.0"?>
-<ZopeData>
-  <record id="1" aka="AAAAAAAAAAE=">
-    <pickle>
-      <tuple>
-        <global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
-        <tuple/>
-      </tuple>
-    </pickle>
-    <pickle>
-      <dictionary>
-        <item>
-            <key> <string>delegated_list</string> </key>
-            <value>
-              <list>
-                <string>title</string>
-                <string>timezone_style</string>
-                <string>editable</string>
-              </list>
-            </value>
-        </item>
-        <item>
-            <key> <string>id</string> </key>
-            <value> <string>listbox_creation_date</string> </value>
-        </item>
-        <item>
-            <key> <string>message_values</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>external_validator_failed</string> </key>
-                    <value> <string>The input failed the external validator.</string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>overrides</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string></string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>tales</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string></string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>values</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>editable</string> </key>
-                    <value> <int>0</int> </value>
-                </item>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string>my_date</string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string>Base_viewFieldLibrary</string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string>Click to edit the target</string> </value>
-                </item>
-                <item>
-                    <key> <string>timezone_style</string> </key>
-                    <value> <int>0</int> </value>
-                </item>
-                <item>
-                    <key> <string>title</string> </key>
-                    <value> <string>Creation Date</string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-      </dictionary>
-    </pickle>
-  </record>
-</ZopeData>
diff --git a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_modification_date.xml b/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_modification_date.xml
deleted file mode 100644
index 3634397ffe..0000000000
--- a/bt5/erp5_web/SkinTemplateItem/portal_skins/erp5_web/WebSection_viewContentList/listbox_modification_date.xml
+++ /dev/null
@@ -1,109 +0,0 @@
-<?xml version="1.0"?>
-<ZopeData>
-  <record id="1" aka="AAAAAAAAAAE=">
-    <pickle>
-      <tuple>
-        <global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
-        <tuple/>
-      </tuple>
-    </pickle>
-    <pickle>
-      <dictionary>
-        <item>
-            <key> <string>delegated_list</string> </key>
-            <value>
-              <list>
-                <string>title</string>
-                <string>timezone_style</string>
-                <string>editable</string>
-              </list>
-            </value>
-        </item>
-        <item>
-            <key> <string>id</string> </key>
-            <value> <string>listbox_modification_date</string> </value>
-        </item>
-        <item>
-            <key> <string>message_values</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>external_validator_failed</string> </key>
-                    <value> <string>The input failed the external validator.</string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>overrides</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string></string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>tales</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string></string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string></string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-        <item>
-            <key> <string>values</string> </key>
-            <value>
-              <dictionary>
-                <item>
-                    <key> <string>editable</string> </key>
-                    <value> <int>0</int> </value>
-                </item>
-                <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string>my_date</string> </value>
-                </item>
-                <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string>Base_viewFieldLibrary</string> </value>
-                </item>
-                <item>
-                    <key> <string>target</string> </key>
-                    <value> <string>Click to edit the target</string> </value>
-                </item>
-                <item>
-                    <key> <string>timezone_style</string> </key>
-                    <value> <int>0</int> </value>
-                </item>
-                <item>
-                    <key> <string>title</string> </key>
-                    <value> <string>Modification Date</string> </value>
-                </item>
-              </dictionary>
-            </value>
-        </item>
-      </dictionary>
-    </pickle>
-  </record>
-</ZopeData>
diff --git a/bt5/erp5_web/bt/template_action_path_list b/bt5/erp5_web/bt/template_action_path_list
index bea0e6b4f3..1a4e43ba9f 100644
--- a/bt5/erp5_web/bt/template_action_path_list
+++ b/bt5/erp5_web/bt/template_action_path_list
@@ -11,7 +11,6 @@ Web Page | view_editor
 Web Page | web_view
 Web Section | generate_section
 Web Section | layout_configuration
-Web Section | list
 Web Section | local_permission
 Web Section | new_default_page
 Web Section | new_page
@@ -27,5 +26,6 @@ Web Site | layout_configuration
 Web Site | local_permission
 Web Site | new_default_page
 Web Site | predicate
+Web Site | section_content
 Web Site | view
 Web Site | web_view
\ No newline at end of file
-- 
2.30.9