[Erp5-report] r40007 nicolas.dumazet - in /erp5/trunk/products/ERP5/bootstrap/erp5_core: Sk...

nobody at svn.erp5.org nobody at svn.erp5.org
Mon Nov 8 05:50:15 CET 2010


Author: nicolas.dumazet
Date: Mon Nov  8 05:50:14 2010
New Revision: 40007

URL: http://svn.erp5.org?rev=40007&view=rev
Log:
2010-11-08 nicolas.dumazet
* Allow changing preferences even if OOo server is not running

Modified:
    erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Preference_getReportFormatItemList.xml
    erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/change_log
    erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Preference_getReportFormatItemList.xml
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Preference_getReportFormatItemList.xml?rev=40007&r1=40006&r2=40007&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Preference_getReportFormatItemList.xml [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/SkinTemplateItem/portal_skins/erp5_core/Preference_getReportFormatItemList.xml [utf8] Mon Nov  8 05:50:14 2010
@@ -60,12 +60,18 @@ style = request.get(\'your_portal_skin\'
 \n
 item_list = [(\'\', \'\')]\n
 \n
-if style == \'ODS\':\n
-  return context.Base_getConversionFormatItemList(\n
-       base_content_type=\'application/vnd.oasis.opendocument.spreadsheet\')\n
-elif style == \'ODT\':\n
-  return context.Base_getConversionFormatItemList(\n
-       base_content_type=\'application/vnd.oasis.opendocument.text\')\n
+from Products.ERP5.Document.Document import ConversionError\n
+\n
+try:\n
+  if style == \'ODS\':\n
+    return context.Base_getConversionFormatItemList(\n
+         base_content_type=\'application/vnd.oasis.opendocument.spreadsheet\')\n
+  elif style == \'ODT\':\n
+    return context.Base_getConversionFormatItemList(\n
+         base_content_type=\'application/vnd.oasis.opendocument.text\')\n
+except ConversionError:\n
+  # OOo server not here, just return empty list\n
+  pass\n
 \n
 return item_list\n
 </string> </value>
@@ -112,6 +118,8 @@ return item_list\n
                             <string>request</string>
                             <string>style</string>
                             <string>item_list</string>
+                            <string>Products.ERP5.Document.Document</string>
+                            <string>ConversionError</string>
                           </tuple>
                         </value>
                     </item>

Modified: erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/change_log
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/change_log?rev=40007&r1=40006&r2=40007&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/change_log [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/change_log [utf8] Mon Nov  8 05:50:14 2010
@@ -1,3 +1,6 @@
+2010-11-08 nicolas.dumazet
+* Allow changing preferences even if OOo server is not running
+
 2010-11-04 nicolas.dumazet
 * provide field in BaseType_view to set up interfaces on portal type classes
 

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=40007&r1=40006&r2=40007&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] (original)
+++ erp5/trunk/products/ERP5/bootstrap/erp5_core/bt/revision [utf8] Mon Nov  8 05:50:14 2010
@@ -1 +1 @@
-1777
\ No newline at end of file
+1778
\ No newline at end of file




More information about the Erp5-report mailing list