Re: Indexing fields
from
Winn King
on Jan 13, 2008 11:11 PM
OK, figured this out finally after stumbling on this in the Plone
Upgrade Guide, in a section about updating add-on products:
http://plone.org/documentation/manual/upgrade-guide/version/2.5-3.0/products/indexes-declared-in-archetypes-schemata-need-to-be-moved-to-genericsetup
You have to add the following to membrane_tool.xml in the profiles
folder of sampleremember:
<index name="getEspressoDrink" meta_type="KeywordIndex">
<indexed_attr value="getEspressoDrink"/>
</index>
<column value="getEspressoDrink"/>
Then go to the portal_setup tool, and after making sampleremember the
active profile, run the import step for 'Membrane Tool'.
Finally, in the advanced tab, click on the 'Update Catalog' button
I'm using Plone 2.5.3 BTW.
Winn King wrote:
> Hi,
> I followed the instructions below from the sampleremember tutorial
> explicitly but expressoDrink is not showing up as an index in the
> membrane catalog. I restarted the zserver and updated the catalog. Is
> there an additional step I'm missing?
>
> How to Make your Member Data Accessible for Quick Catalog Searches
>
> One of the big benefits of using remember is that data can easily be
> placed into ZCatalog indexes and metadata fields. This allows you to
> use the familiar catalog API calls to search a site membership. To
> place the espressoDrink schema fields into the stock catalog that
> comes with membrane, "index='membrane_tool/KeywordIndex:brains'," is
> added to the following code::
>
> atapi.StringField(
> 'espressoDrink',
> required=1,
> index='membrane_tool/KeywordIndex:brains',
> widget=atapi.StringWidget(
> label="Your Favorite Espresso Drink",
> description="Enter your favorite Espresso Drink."),
> regfield=0,
> ),
>
>
> --
> Archive:
> http://www.openplans.org/projects/remember/lists/remember/archive/2008/01/1200179557964
>
> To unsubscribe send an email with subject unsubscribe to
> remember@.... Please contact
> remember-manager@... for questions.
>
>