[Zope] CatalogPathAwareness and manage_beforeDelete

Bakhtiar A Hamid kedai@kedai.com.my
Tue, 17 Dec 2002 18:12:05 +0800


hello all
i have a product that subclass CatalogPathAwareness and SimpleItem all wo=
rks=20
ok.  i,e an object instance will be added and deleted from the catalog

however, if i override manage_beforeDelete, the catalog is not cleared wh=
en i=20
delete the object instance

is that natural?  do i have to supply my own uncatalog_object ?

with this snippet, it still doesnt work.  i guess i don't get what uid fo=
r=20
uncatalog_object is ...

here's the snippet

        def manage_beforeDelete(self, item, container):
                """method for delete /cut/paste/rename"""
                img_dir =3D getattr(self.aq_parent, 'images')
                img_dir.manage_delObjects([item.getId()+'_image'])
                self.uncatalog_object(item.absolute_url(1))


thanks

--=20

=09http://www.kedai.com.my/             http://www.kedai.com.my/eZine
=09http://www.zope.org/Members/kedai    http://www.my-zope.org
=09Am I Evil?