Fw: [Zope] Deleting objects

Chris Withers lists at simplistix.co.uk
Fri Apr 2 03:35:55 EST 2004


Serg wrote:

>  I mean overloading manage_beforeDelete. How can I overloading function
>  manage_beforeDelete in order to manage delete operation?
>  For example:
>  def manage_beforeDelete(self, item, container):
>    if "something":
>      #allow delete
>   else:
>     #reject delete

class myClass (ObjectManager):

   def manage_beforeDelete(self,item,container):
      if self.REQUEST.get('really_delete_me'):
         return ObjectManager.manage_beforeDelete(self,item,container)

cheers,

Chris

-- 
Simplistix - Content Management, Zope & Python Consulting
            - http://www.simplistix.co.uk




More information about the Zope mailing list