[Erp5-report] r16963 - /erp5/trunk/products/ERP5OOo/OOoUtils.py
nobody at svn.erp5.org
nobody at svn.erp5.org
Thu Oct 11 22:09:46 CEST 2007
Author: jp
Date: Thu Oct 11 22:09:46 2007
New Revision: 16963
URL: http://svn.erp5.org?rev=16963&view=rev
Log:
Added support for acquisition.
Modified:
erp5/trunk/products/ERP5OOo/OOoUtils.py
Modified: erp5/trunk/products/ERP5OOo/OOoUtils.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5OOo/OOoUtils.py?rev=16963&r1=16962&r2=16963&view=diff
==============================================================================
--- erp5/trunk/products/ERP5OOo/OOoUtils.py (original)
+++ erp5/trunk/products/ERP5OOo/OOoUtils.py Thu Oct 11 22:09:46 2007
@@ -29,6 +29,8 @@
import sys
+from Acquisition import Implicit
+
from Products.PythonScripts.Utility import allow_class
from ZPublisher.HTTPRequest import FileUpload
from xml.dom.ext.reader import PyExpat
@@ -63,7 +65,7 @@
'sxm' : 'application/vnd.sun.xml.math',
}
-class OOoBuilder:
+class OOoBuilder(Implicit):
"""
Tool that allows to reinject new files in a ZODB OOo document.
"""
@@ -218,7 +220,7 @@
InitializeClass(OOoBuilder)
allow_class(OOoBuilder)
-class OOoParser:
+class OOoParser(Implicit):
"""
General purpose tools to parse and handle OpenOffice v1.x documents.
"""
@@ -553,3 +555,7 @@
InitializeClass(OOoParser)
allow_class(OOoParser)
allow_class(CorruptedOOoFile)
+
+def newOOoParser(container):
+ return OOoParser().__of__(container)
+
More information about the Erp5-report
mailing list