Home » Liferay Portal » English » 3. Development

Kombinierte Ansicht Flache Ansicht Baumansicht
Threads [ Zurück | Nächste ]
Phoenix Zerin
Integrating expando values into image gallery search
28. September 2011 09:11

Phoenix Zerin

Rang: Junior Member

Nachrichten: 60

Eintrittsdatum: 28. Juni 2011

Neue Beiträge

I'm working on a "photo gallery" portlet that allows the user to search through images on the site.

Not all images should be available to the photo gallery, however; some are classified as utility images (such as backgrounds, caps, headers/banners, etc.).

The easy solution to this problem would be to create a separate folder in the image gallery that contains "non-photo gallery" images. However, there are also a few "one-offs" (the images qualify as content, but the content strategy team don't want them to appear in the photo gallery).

As an alternative approach, I used an expando value named "photo gallery", which contains either "true" or "false".

Using the information in this article I was able to find a way to filter images in the image gallery based on this expando value, but I am at a loss as to how to integrate this filter into a Lucene search.

What do I need to do to get this to work?
Jelmer Kuperus
RE: Integrating expando values into image gallery search
28. September 2011 09:51

Jelmer Kuperus

Rang: Liferay Legend

Nachrichten: 1192

Eintrittsdatum: 10. März 2010

Neue Beiträge

If i recall correctly expandos are included in the lucene index as expando/expandoname so this means that you can add it as a required term when searching

Participate in the State of Liferay Community 2017. Help the community and even win some prizes!