Commit 9bed8678 authored by Sebastien Robin's avatar Sebastien Robin

get the content of a cpsdocument in a different way


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@353 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent cfffbdc7
...@@ -77,9 +77,10 @@ class PatchedCPSDocument(CPSDocument): ...@@ -77,9 +77,10 @@ class PatchedCPSDocument(CPSDocument):
""" """
accessor_name = 'get' + UpperCase(key) accessor_name = 'get' + UpperCase(key)
aq_self = aq_base(self) aq_self = aq_base(self)
if hasattr(aq_self, accessor_name): if key!='content':
method = getattr(self, accessor_name) if hasattr(aq_self, accessor_name):
return method() method = getattr(self, accessor_name)
return method()
prop_type = self.getPropertyType(key) # XXX added by Seb prop_type = self.getPropertyType(key) # XXX added by Seb
if prop_type in ('object',): if prop_type in ('object',):
if hasattr(aq_self, key): if hasattr(aq_self, key):
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment