Hello, If I understand correctly then CatalogAware classes notify the catalog when they are added, or deleted. What happens when they are moved? More q'n : 1. Do classes have an event when they are moved? so that you can rewrite this event to update the class when moved? 2. Can you force a class to update itself? Thanks in advance, Tom.
Tom Deprez wrote:
If I understand correctly then CatalogAware classes notify the catalog when they are added, or deleted.
What happens when they are moved?
WHen an object is moved it's deleted from it's original location, so the manage_beforeDelete method gets called and it unindexes the object. Then the object is added and another method is called (manage_afterAdd) which indexes it.
2. Can you force a class to update itself?
call the method reindex_object(): <dtml-call "reindex_object()"> in DTML or self.reindex_object() in python -- -= This is NOT a pyramid scheme =- The SNAFU Principle: True communication is possible only between equals Itamar S.T. itamars@ibm.net
participants (2)
-
Itamar Shtull-Trauring -
Tom Deprez