When a user selects a facet value, a new query is issued with this selection applied as a constraint. The search engine returns the results of this query and a new set of facets. By default, the new facet set does not include the other selection values for the selected facet. So, for example, if the selection values for the Color facet are Red, Green, and Blue, and the user selects Red, the facet set returned does not include the Green and Blue selection values, because the green and blue items have already been removed from the search results. Removing these selection values is called filtering the facet.
There are a certain cases where filtering the facet may not be the desired behavior:
If you have a facet based on the
product
item’sancestorCategories
property, when a user selects a category, you typically will want lower-level category selections to still be available for further navigation. See Skipping Facet Values in the Facet Trail for information about removing the higher-level category selections.If your faceted search implementation supports multiple selection values, you may want the unselected facet values to be returned, so the user can further refine on the same facet. This is particularly true if the facet values are combined using Boolean AND, so you can allow the user to further restrict the current result set. See Supporting Multiple Selection Values for more information.
The search engine filters all facets unless the refinement configuration specifies otherwise. To disable filtering of an individual facet, you add the faceting property to the filterProperties
array property of the /atg/commerce/search/refinement/RefinementConfigurationXMLGenerator
component. By default, this property is set to:
filterProperties=\
ancestorCategories.$repositoryId,\
ancestorCategories.displayName
If you have additional facets that you do not want to be filtered, add the faceting properties to this array. For example:
filterProperties+=paperSizes