[Erp5-report] r32851 ivan - /erp5/trunk/products/ERP5/Document/
nobody at svn.erp5.org
nobody at svn.erp5.org
Fri Feb 19 13:53:10 CET 2010
Author: ivan
Date: Fri Feb 19 13:53:08 2010
New Revision: 32851
URL: http://svn.erp5.org?rev=32851&view=rev
Log:
Explicitly check if hasData do exists. As Document is an abstract class such a check should be avoided and all inheriting classes should implement the standard hasBaseData method.
Modified:
erp5/trunk/products/ERP5/Document/Document.py
erp5/trunk/products/ERP5/Document/Gadget.py
erp5/trunk/products/ERP5/Document/Image.py
Modified: erp5/trunk/products/ERP5/Document/Document.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/Document.py?rev=32851&r1=32850&r2=32851&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/Document.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/Document.py [utf8] Fri Feb 19 13:53:08 2010
@@ -985,7 +985,7 @@
Based on the document content, find out as many properties as needed.
returns properties which should be set on the document
"""
- if not self.hasData():
+ if getattr(self, 'hasData', None) is not None and not self.hasData():
# if document is empty, we will not find anything in its content
return dict()
if not self.hasBaseData():
Modified: erp5/trunk/products/ERP5/Document/Gadget.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/Gadget.py?rev=32851&r1=32850&r2=32851&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/Gadget.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/Gadget.py [utf8] Fri Feb 19 13:53:08 2010
@@ -31,7 +31,7 @@
class Gadget(XMLObject):
"""
- An Gadget object holds a template information for an ERP5 Gadget part of ERP5 UI).
+ An Gadget object holds a template information for an ERP5 Gadget (part of ERP5 UI).
"""
meta_type = 'ERP5 Gadget'
Modified: erp5/trunk/products/ERP5/Document/Image.py
URL: http://svn.erp5.org/erp5/trunk/products/ERP5/Document/Image.py?rev=32851&r1=32850&r2=32851&view=diff
==============================================================================
--- erp5/trunk/products/ERP5/Document/Image.py [utf8] (original)
+++ erp5/trunk/products/ERP5/Document/Image.py [utf8] Fri Feb 19 13:53:08 2010
@@ -414,7 +414,7 @@
parameter_list.append('%s:-' % format)
else:
parameter_list.append('-')
-
+ #self.log(parameter_list)
process = subprocess.Popen(parameter_list,
stdin=subprocess.PIPE,
stdout=subprocess.PIPE,
More information about the Erp5-report
mailing list