[Zope] ZClasses and ZCatalog: reindexing problem
Jason Spisak
444@hiretechs.com
Thu, 20 Apr 2000 15:43:14 GMT
Anthony,
1)
> I can add a new catalog-aware class instance which the Catalog will pick up,
> but the properties of this new instance (author, pub_title, publisher, year,
> etc.) are not made available to search results;
Do you call <dtml-call reindex_object> when you add you instnace like so:
<dtml-with "MyZClass.createInObjectManager(REQUEST['id'], REQUEST)">
<dtml-call "propertysheets.MyProperties.manage_editProperties(REQUEST)">
<dtml-call reindex_object>
</dtml-with>
You must call it after you change the instance's properties.
You also must do so anytime you edit those properties. That means you
can't call '/propertysheets/MyProperties/manage' to edit them. You must
construct you own DTML.
2) the addition of this new
> instance prevents the ZSearch interface from returning results for any other
> query, even for ones that worked before the addition.
This is probably because your search and report are reporting properties
from you ZClass like 'author', but not all the items in the Catalog have
the 'author' property. If you are searching for a particular 'meta_type'
like a 'ZBook', that has a property 'author', if you don't narrow down you
search to just ZBook's, the report page will ask for the 'author' property
of plain old 'Folders'. And plain old 'Folders' don't have an author
property. And you'll get a traceback.
Hope that helps,
Jason Spisak
CIO
HireTechs.com
6151 West Century Boulevard
Suite 900
Los Angeles, CA 90045
P. 310.665.3444
F. 310.665.3544
Under US Code Title 47, Sec.227(b)(1)(C), Sec.227(a)(2)(B) This email
address may not be added to any commercial mail list with out my
permission. Violation of my privacy with advertising or SPAM will
result in a suit for a MINIMUM of $500 damages/incident, $1500 for
repeats.