From 37a8fb3e0d2fb196b29b0403a7c6bef32c8835b3 Mon Sep 17 00:00:00 2001
From: Gabriel Monnerat <gabriel@tiolive.com>
Date: Mon, 28 Mar 2011 20:55:02 +0000
Subject: [PATCH] remove dependency of erp5_configurator_standard

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@44702 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 ...iguration_getUNGPreferredDateOrderList.xml |  75 +++++++
 .../your_lang.xml                             |   2 +-
 .../your_preferred_date_order.xml             |   2 +-
 .../your_default_available_language.xml       | 195 +++++++++++++++---
 bt5/erp5_configurator_ung/bt/revision         |   2 +-
 5 files changed, 248 insertions(+), 28 deletions(-)
 create mode 100644 bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_getUNGPreferredDateOrderList.xml

diff --git a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_getUNGPreferredDateOrderList.xml b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_getUNGPreferredDateOrderList.xml
new file mode 100644
index 0000000000..66764d95da
--- /dev/null
+++ b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_getUNGPreferredDateOrderList.xml
@@ -0,0 +1,75 @@
+<?xml version="1.0"?>
+<ZopeData>
+  <record id="1" aka="AAAAAAAAAAE=">
+    <pickle>
+      <global name="PythonScript" module="Products.PythonScripts.PythonScript"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>Script_magic</string> </key>
+            <value> <int>3</int> </value>
+        </item>
+        <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>
+                            <item>
+                                <key> <string>name_container</string> </key>
+                                <value> <string>container</string> </value>
+                            </item>
+                            <item>
+                                <key> <string>name_context</string> </key>
+                                <value> <string>context</string> </value>
+                            </item>
+                            <item>
+                                <key> <string>name_m_self</string> </key>
+                                <value> <string>script</string> </value>
+                            </item>
+                            <item>
+                                <key> <string>name_subpath</string> </key>
+                                <value> <string>traverse_subpath</string> </value>
+                            </item>
+                          </dictionary>
+                        </value>
+                    </item>
+                  </dictionary>
+                </state>
+              </object>
+            </value>
+        </item>
+        <item>
+            <key> <string>_body</string> </key>
+            <value> <string>Base_translateString = context.Base_translateString\n
+date_order_list = [\n
+  (\'\', \'\'),\n
+  (Base_translateString(\'Year / Month / Day\'), \'ymd\'),\n
+  (Base_translateString(\'Day / Month / Year\'), \'dmy\'),\n
+  (Base_translateString(\'Month / Day / Year\'), \'mdy\'),\n
+]\n
+\n
+return date_order_list\n
+</string> </value>
+        </item>
+        <item>
+            <key> <string>_params</string> </key>
+            <value> <string></string> </value>
+        </item>
+        <item>
+            <key> <string>id</string> </key>
+            <value> <string>BusinessConfiguration_getUNGPreferredDateOrderList</string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+</ZopeData>
diff --git a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_lang.xml b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_lang.xml
index b877c597cb..724f91b76c 100644
--- a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_lang.xml
+++ b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_lang.xml
@@ -278,7 +278,7 @@
       <dictionary>
         <item>
             <key> <string>_text</string> </key>
-            <value> <string>python: [(x[\'name\'], x[\'bt5\']) for x in context.BusinessConfiguration_getAvailableL10NBusinessTemplateList()]</string> </value>
+            <value> <string>python: [(x[\'name\'], x[\'bt5\']) for x in context.BusinessConfiguration_getUNGAvailableL10NBusinessTemplateList()]</string> </value>
         </item>
       </dictionary>
     </pickle>
diff --git a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_preferred_date_order.xml b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_preferred_date_order.xml
index ede4eab492..d10a3be499 100644
--- a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_preferred_date_order.xml
+++ b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGPreferencesForm/your_preferred_date_order.xml
@@ -284,7 +284,7 @@
       <dictionary>
         <item>
             <key> <string>_text</string> </key>
-            <value> <string>here/BusinessConfiguration_getPreferredDateOrderList</string> </value>
+            <value> <string>here/BusinessConfiguration_getUNGPreferredDateOrderList</string> </value>
         </item>
       </dictionary>
     </pickle>
diff --git a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGWebSiteForm/your_default_available_language.xml b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGWebSiteForm/your_default_available_language.xml
index 262b19d04a..4a27e9bc71 100644
--- a/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGWebSiteForm/your_default_available_language.xml
+++ b/bt5/erp5_configurator_ung/SkinTemplateItem/portal_skins/erp5_configurator_ung/BusinessConfiguration_setupUNGWebSiteForm/your_default_available_language.xml
@@ -2,20 +2,10 @@
 <ZopeData>
   <record id="1" aka="AAAAAAAAAAE=">
     <pickle>
-      <global name="ProxyField" module="Products.ERP5Form.ProxyField"/>
+      <global name="RadioField" module="Products.Formulator.StandardFields"/>
     </pickle>
     <pickle>
       <dictionary>
-        <item>
-            <key> <string>delegated_list</string> </key>
-            <value>
-              <list>
-                <string>items</string>
-                <string>orientation</string>
-                <string>title</string>
-              </list>
-            </value>
-        </item>
         <item>
             <key> <string>id</string> </key>
             <value> <string>your_default_available_language</string> </value>
@@ -28,6 +18,14 @@
                     <key> <string>external_validator_failed</string> </key>
                     <value> <string>The input failed the external validator.</string> </value>
                 </item>
+                <item>
+                    <key> <string>required_not_found</string> </key>
+                    <value> <string>Input is required but no input given.</string> </value>
+                </item>
+                <item>
+                    <key> <string>unknown_selection</string> </key>
+                    <value> <string>You selected an item that was not in the list.</string> </value>
+                </item>
               </dictionary>
             </value>
         </item>
@@ -36,15 +34,67 @@
             <value>
               <dictionary>
                 <item>
-                    <key> <string>field_id</string> </key>
+                    <key> <string>alternate_name</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>css_class</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>default</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>description</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>editable</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>enabled</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>external_validator</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>extra_item</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>first_item</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>hidden</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>items</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>orientation</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>required</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>title</string> </key>
                     <value> <string></string> </value>
                 </item>
                 <item>
-                    <key> <string>form_id</string> </key>
+                    <key> <string>unicode</string> </key>
                     <value> <string></string> </value>
                 </item>
                 <item>
-                    <key> <string>target</string> </key>
+                    <key> <string>whitespace_preserve</string> </key>
                     <value> <string></string> </value>
                 </item>
               </dictionary>
@@ -55,31 +105,73 @@
             <value>
               <dictionary>
                 <item>
-                    <key> <string>field_id</string> </key>
+                    <key> <string>alternate_name</string> </key>
                     <value> <string></string> </value>
                 </item>
                 <item>
-                    <key> <string>form_id</string> </key>
+                    <key> <string>css_class</string> </key>
                     <value> <string></string> </value>
                 </item>
                 <item>
-                    <key> <string>items</string> </key>
+                    <key> <string>default</string> </key>
                     <value>
                       <persistent> <string encoding="base64">AAAAAAAAAAI=</string> </persistent>
                     </value>
                 </item>
+                <item>
+                    <key> <string>description</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>editable</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>enabled</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>external_validator</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>extra_item</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>first_item</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>hidden</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>items</string> </key>
+                    <value>
+                      <persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
+                    </value>
+                </item>
                 <item>
                     <key> <string>orientation</string> </key>
                     <value> <string></string> </value>
                 </item>
                 <item>
-                    <key> <string>target</string> </key>
+                    <key> <string>required</string> </key>
                     <value> <string></string> </value>
                 </item>
                 <item>
                     <key> <string>title</string> </key>
                     <value> <string></string> </value>
                 </item>
+                <item>
+                    <key> <string>unicode</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>whitespace_preserve</string> </key>
+                    <value> <string></string> </value>
+                </item>
               </dictionary>
             </value>
         </item>
@@ -88,12 +180,44 @@
             <value>
               <dictionary>
                 <item>
-                    <key> <string>field_id</string> </key>
-                    <value> <string>my_radio_field</string> </value>
+                    <key> <string>alternate_name</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>css_class</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>default</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>description</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>editable</string> </key>
+                    <value> <int>1</int> </value>
+                </item>
+                <item>
+                    <key> <string>enabled</string> </key>
+                    <value> <int>1</int> </value>
+                </item>
+                <item>
+                    <key> <string>external_validator</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>extra_item</string> </key>
+                    <value> <string></string> </value>
+                </item>
+                <item>
+                    <key> <string>first_item</string> </key>
+                    <value> <int>0</int> </value>
                 </item>
                 <item>
-                    <key> <string>form_id</string> </key>
-                    <value> <string>Base_viewWebFieldLibrary</string> </value>
+                    <key> <string>hidden</string> </key>
+                    <value> <int>0</int> </value>
                 </item>
                 <item>
                     <key> <string>items</string> </key>
@@ -106,13 +230,21 @@
                     <value> <string>vertical</string> </value>
                 </item>
                 <item>
-                    <key> <string>target</string> </key>
-                    <value> <string>Click to edit the target</string> </value>
+                    <key> <string>required</string> </key>
+                    <value> <int>0</int> </value>
                 </item>
                 <item>
                     <key> <string>title</string> </key>
                     <value> <string>Default Language</string> </value>
                 </item>
+                <item>
+                    <key> <string>unicode</string> </key>
+                    <value> <int>0</int> </value>
+                </item>
+                <item>
+                    <key> <string>whitespace_preserve</string> </key>
+                    <value> <int>0</int> </value>
+                </item>
               </dictionary>
             </value>
         </item>
@@ -127,7 +259,20 @@
       <dictionary>
         <item>
             <key> <string>_text</string> </key>
-            <value> <string>python: [(x[\'name\'], x[\'id\']) for x in context.BusinessConfiguration_getAvailableL10NBusinessTemplateList()]</string> </value>
+            <value> <string>python: getattr(here, field.getId().replace(\'your_\',\'\',1), \'\')</string> </value>
+        </item>
+      </dictionary>
+    </pickle>
+  </record>
+  <record id="3" aka="AAAAAAAAAAM=">
+    <pickle>
+      <global name="TALESMethod" module="Products.Formulator.TALESField"/>
+    </pickle>
+    <pickle>
+      <dictionary>
+        <item>
+            <key> <string>_text</string> </key>
+            <value> <string>python: [(x[\'name\'], x[\'id\']) for x in context.BusinessConfiguration_getUNGAvailableL10NBusinessTemplateList()]</string> </value>
         </item>
       </dictionary>
     </pickle>
diff --git a/bt5/erp5_configurator_ung/bt/revision b/bt5/erp5_configurator_ung/bt/revision
index 3cacc0b93c..ca7bf83ac5 100644
--- a/bt5/erp5_configurator_ung/bt/revision
+++ b/bt5/erp5_configurator_ung/bt/revision
@@ -1 +1 @@
-12
\ No newline at end of file
+13
\ No newline at end of file
-- 
2.30.9