ShowTable of Contents
IBM WebSphere Portal V8 provides Search Center portlet as a main portlet for searching against various content. This Portlet is implemented over Portal Search REST Public API and utilizes only basic capabilities. In this article we would like to present a more advanced portlet – Explorative Navigation Portlet
, which is fully based on the Search REST capabilities
and could be easily customized in order to fit customer's needs and allows customers to use benefits of faceted search, documents browsing and sophisticated filtering.
With introducing new WCM feature in Portal 8 – when WCM content is tagged, tags are published on WCM seedlist, customers would like to be able to search with tags against their WCM content and reveal relevant search results. Explorative Navigation Portlet allows users to perform faceted search on facets that Search Administrator could configure according to the seedlist published fields. Tags could be configured this way and users get the best 10 tags in the separate section in the portlet and gain advanced filtering on them. Not only tags could be configured this way, but any other field in the seedlist that Search Administrator thinks it is relevant for the needs of his company's content.
In addition to faceted search, users can use benefit of sorting not only by date, but by any other configured fields, like popularity and rating in our #Downloads" title="sample seedlist">sample seedlist
that is attached to this article, and, of course, could be modified according to customer's requirements.
This article explains this new portlet architecture and provides detailed examples with code snippets that will allow Search Administrator customize it according to the site content.
We also assume that your Portal is upgraded to WebSphere Portal 8 CF03, where required configuration for facets and sorting is exposed. See below Additional+configuration
Search API Overview
Search REST API specification
Explorative Navigation Portlet Sample
Portlet Features Description
Explorative Navigation Portlet screen is divided into main table area and filters area. The main area occupies the majority of the space and is a table-like list of displayed documents. The documents in the table are filtered according to the applied filters, selected in each filtering widget. When any filter is applied it also appears above the table of results in a convenient manner. If any filter is removed, the table will be updated accordingly and a new state of the selected filters will be shown.
Main table widget
Main results table occupies most of the screen space in the Explorative Navigation Portlet. The table contains a list of shown documents, each document occupies a row in the table. There are 5 predefined columns in the table:
• document icon – graphic icon supplied on the document seedlist
• document Title – Document title
• document Last update date – Date of last update
• document rating – document rating, each document has a rating ratio from 1 to 5. The rating is an average rating provided as a user feedback.
• document popularity – number of document downloads
All the columns, except for the Icon column, have a clickable header, which provides a sorting functionality. The table shows all the available search results, with filters applied on it. When a new search query is sent to the server, or one of the filtering options is changed, the table results are updated accordingly.
Applied Filters removable controls
When any filtering option is selected, and a filter is applied on the table of results, a special removable filter control appears above the header of the results table. There can be only one removable filter control for each filtering widget. When an “X” option is clicked on the filtering control the applied filter is removed, and the whole view is updated according to the new selection. When the appropriate filtering widget is clicked and a new value is selected, the removable control is updated according to the new value.
The tags widget show a list of top tags, from the document currently shown in the results table. The tags are shown in the descending order by their popularity. When any tag is clicked, its value is shown in the appropriate removable filtering option, and only the documents tagged with this tag will appear in the results table. Selection of multiple tags is supported.
Rating widget is a scrollable control, which enables a selection of one of values between 1 to 5. Each document has a rating grade calculated as average of user feedback provided voluntarily by the users. The rating is always a natural number between 1 and 5. When 2 is selected, then only documents with rating above or equal to 2 will be presented in the results table.
Popularity widget is a scrollable control, which enables a selection of any value between 0 and some predefined value for the maximal document popularity (in our case it is 100000 views). Each document has a popularity rating based on the number of times the document was reviewed by users. When some value is is selected in the control, only documents with popularity rating above or equal to this number will be presented in the results table.