From 9d777e904fd58095cae6ec8fd93638a61bf8e613 Mon Sep 17 00:00:00 2001
From: Gabriel Monnerat <gabriel@tiolive.com>
Date: Fri, 11 Mar 2011 20:23:20 +0000
Subject: [PATCH] don't load ERP5 System Preference to UNG Settings

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@44217 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 .../Base_getPreferencePathList.xml               |  4 ----
 .../erp5_web_ung_theme/ung_js/ung.js.xml         | 16 ++--------------
 bt5/erp5_web_ung_theme/bt/revision               |  2 +-
 3 files changed, 3 insertions(+), 19 deletions(-)

diff --git a/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/Base_getPreferencePathList.xml b/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/Base_getPreferencePathList.xml
index 9f4efaa9bb..95e2e36c55 100644
--- a/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/Base_getPreferencePathList.xml
+++ b/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/Base_getPreferencePathList.xml
@@ -57,16 +57,12 @@ if context.portal_membership.isAnonymousUser():\n
 \n
 portal_preferences = context.portal_preferences\n
 preference = portal_preferences.getActivePreference()\n
-system_preference = portal_preferences.getActiveSystemPreference()\n
 \n
 preference_dict = {}\n
 \n
 if preference:\n
   preference_dict["preference"] = preference.getRelativeUrl()\n
 \n
-if system_preference:\n
-  preference_dict["system_preference"] = system_preference.getRelativeUrl()\n
-\n
 return dumps(preference_dict)\n
 </string> </value>
         </item>
diff --git a/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/ung_js/ung.js.xml b/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/ung_js/ung.js.xml
index 8e76649e0c..6994a7189f 100644
--- a/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/ung_js/ung.js.xml
+++ b/bt5/erp5_web_ung_theme/SkinTemplateItem/portal_skins/erp5_web_ung_theme/ung_js/ung.js.xml
@@ -373,8 +373,8 @@ $().ready(function(){\n
   });\n
   $("div#preference_dialog").dialog({\n
     autoOpen: false,\n
-    height: 480,\n
-    width: 330,\n
+    height: 215,\n
+    width: 319,\n
     modal:true,\n
     buttons: {\n
       "Save": function(){\n
@@ -383,11 +383,6 @@ $().ready(function(){\n
           url: ungPreferencePath + "/Base_edit",\n
           data: erp5PreferenceArgument + "&form_id=Preference_viewHtmlStyle",\n
         });\n
-        var systemPreferenceArgument = $("form#system_preference").serialize();\n
-        $.ajax({\n
-          url: systemPreferencePath + "/Base_edit",\n
-          data: systemPreferenceArgument + "&form_id=SystemPreference_view",\n
-        });\n
         var ungPreferenceArgument = $("form#ung_preference").serialize();\n
         $.ajax({\n
           url: ungPreferencePath + "/Base_edit",\n
@@ -432,19 +427,12 @@ $().ready(function(){\n
       if ($("div#preference_dialog").html() == ""){\n
         $.getJSON("Base_getPreferencePathList", function(data){\n
           ungPreferencePath = data.preference;\n
-          systemPreferencePath = data.system_preference;\n
           $.get(ungPreferencePath + \'/Preference_viewHtmlStyle?editable_mode:int=1\', function(data){\n
             $("div#preference_dialog").append("<form id=\'erp5_preference\'>" + \n
                                               "<fieldset class=\'center editable\'>" + \n
                                               $(data).find(\'fieldset.center.editable\').html() +\n
                                               "</fieldset></form>");\n
           });\n
-          $.get(systemPreferencePath + \'/SystemPreference_view?editable_mode:int=1\', function(data){\n
-            $("div#preference_dialog").append("<form id=\'system_preference\'>" + \n
-                                              "<fieldset class=\'right editable\'>" + \n
-                                              $(data).find(\'fieldset.right.editable\').html() +\n
-                                              "</fieldset></form>");\n
-          });\n
           $.get(ungPreferencePath + \'/UNGPreference_view?editable_mode:int=1\', function(data){  \n
             $("div#preference_dialog").append("<form id=\'ung_preference\'>" + \n
                                               "<fieldset class=\'center editable\'>" + \n
diff --git a/bt5/erp5_web_ung_theme/bt/revision b/bt5/erp5_web_ung_theme/bt/revision
index 6eac4a65cd..8975db9a05 100644
--- a/bt5/erp5_web_ung_theme/bt/revision
+++ b/bt5/erp5_web_ung_theme/bt/revision
@@ -1 +1 @@
-292
\ No newline at end of file
+293
\ No newline at end of file
-- 
2.30.9