Making a Z Class and a Z Catalog get along - PropertyManager?
I've managed to succesfully create my Z Class product so that it enters itself into the Z Catalog on creation. Hooray for me. Now, the goal of this task I'm undertaking is to allow web pages to have specific properties associated with them, and these properties are automagically searchable. That is why I made the Z Class which is based in PageTemplate, as it needs to behave pretty much like a page template, but have two properties that are searchable. Now, I've seen it mentioned in passing that the PropertyManager is not catalog aware, and as such I'm not so surprised to learn that the objects I create do not have their changes to their properies reflected in the Catalog. Where I saw this mentioned was a post to the effect of "Make sure you make PropertyManager catalog aware!" How do I make PropertyManager catalog aware, and only aware for this specific ZClass? As a more general question: Can anyone direct me to some Zope resources suitable for intermediate questions such as this? I have the Zope Book in front of me, but that only covers the basics, and I can't find much in the way of usefull information on Zope.org. (Or is that just me?) Anything else out there so I don't have to wander around asking silly questions? Ed
Edward Pollard writes:
... Now, I've seen it mentioned in passing that the PropertyManager is not catalog aware, and as such I'm not so surprised to learn that the objects I create do not have their changes to their properies reflected in the Catalog. "Catalog Awareness" helps you only to handle creation and deletion and never modification.
There are incredibly many ways to change an object such that a standard class is unable to handle them all.
... How do I make PropertyManager catalog aware, and only aware for this specific ZClass? You do not.
Instead provide your own methods to change the properties. They probably will call "manage_changeProperties" (either the one of the PropertyManager or (more likely) from a PropertySheet) and finally call the method "index_object".
As a more general question: Can anyone direct me to some Zope resources suitable for intermediate questions such as this? This list is not bad.
Usually, we appreciate when you have already looked at the mailing list archives (searchable via Google) as it is somewhat uninteresting to always answer the same questions ;-)
I have the Zope Book in front of me, but that only covers the basics You may also look at
<http://www.dieter.handshake.de/pyprojects/zope/book/chap3.html> Of course, it, too, does not answer all questions (just a few ones). , and I can't find much
in the way of usefull information on Zope.org. There are numerous other resources, e.g. "www.zopelabs.com".
... Anything else out there so I don't have to wander around asking silly questions? It was not that silly...
Come back with other similar questions when a search in the mailing list archives did not provide an answer. Dieter
participants (2)
-
Dieter Maurer -
Edward Pollard