Commit 42ddd8ea authored by Jean-Paul Smets's avatar Jean-Paul Smets

Override setDescription method so that we use ERP5Type accessors (which are...

Override setDescription method so that we use ERP5Type accessors (which are capable of casting values) rather than CMF default setDescription method.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@22574 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 846ba5e6
...@@ -90,6 +90,17 @@ class XMLObject( Folder ): ...@@ -90,6 +90,17 @@ class XMLObject( Folder ):
property_sheets = ( PropertySheet.Base property_sheets = ( PropertySheet.Base
, PropertySheet.XMLObject ) , PropertySheet.XMLObject )
# Inheritance fixes
security.declareProtected( Permissions.ModifyPortalContent, 'setDescription' )
def setDescription(self, value):
"""
Sets the description by invoking the Accessor
based method rather than the one inherited from CMF.
This is require to make sure that value is casted
"""
self._setDescription(value)
self.reindexObject()
security.declareProtected( Permissions.ModifyPortalContent, 'XUpdateDocument' ) security.declareProtected( Permissions.ModifyPortalContent, 'XUpdateDocument' )
def XUpdateDocument(self, xupdate): def XUpdateDocument(self, xupdate):
""" """
......
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