Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

Code Block
languagejson
{
      "type": "FieldFacet",
      "title": "Extension",
      "field": "extension",
      "op": "OR",
      "minShow": 2,
      "maxShow": 5,
      "show": true,
      "sendToSolr": true
    },

Parameters

Name

Optional

Default value

Description

title

The title showed at the top of the facet

field

The solr field associated to the facet

op

Operator, either “OR” or “AND”. Tells how documents are shown when selecting multiple entries in the facet. If “OR” documents need to have at least one selected element in the concerned field to be selected. If “AND” they need to have all selected elements as part of the concerned field

minShow

The maximum number of elements that are shown if the facet is not expanded

maxShow

The maximum number of elements that are shown if the facet is expanded (after clicking show more)

variant

yes

checkbox

Specify the type of FieldFacet to use. It can take these values :

  • title: the title showed at the top of the facet

  • field: the solr field associated to the facet

  • op: operator, either “OR” or “AND”. Tells how documents are shown when selecting multiple entries in the facet. If “OR” documents need to have at least one selected element in the concerned field to be selected. If “AND” they need to have all selected elements as part of the concerned field

  • minShow: The maximum number of elements that are shown if the facet is not expanded

  • maxShow: The maximum number of elements that are shown if the facet is expanded (after clicking show more)

  • variant (optional) : specify the type of FieldFacet to use. It can take these values :

    • checkbox (default) : use classic FieldFacet with a checkbox list

    • autocomplete : use a search bar with autocomplete

  • show (optional, default is true) : True to display the FieldFacet in the left panel. This option is only an UI effect. The facet is still registered as a field facet in the query.

  • sendToSolr (optional, default is false): Set to true to force the query to Solr even if show is false (keep in mind that if show is true, the facet is queried whatever the value of the sendToSolr parameter). Required to be true for the use of field facet tabs (https://datafari.atlassian.net/wiki/spaces/DATAFARI/pages/2625634305/Customizing+DatafariUI#Search-Tabs ), which is its only purpose for now.

...

You can decide which fields to display in the advanced search dropdown lists, and which labels to use. For that, please refer to Advanced search - Fixed values list for fields and labeled fieds

Customizing colors and theme

...