Uploaded image for project: 'XWiki Platform'
  1. XWiki Platform
  2. XWIKI-21127

Allow configuring facet that are automatically expanded in Solr search

    XMLWordPrintable

Details

    • New Feature
    • Resolution: Unresolved
    • Major
    • None
    • None
    • Search - Solr
    • None
    • Unknown

    Description

      A client asked for auto expansion of a particular facet in Solr search. reading the code of xwiki-platform-core/xwiki-platform-search/xwiki-platform-search-solr/xwiki-platform-search-solr-ui/src/main/resources/Main/SolrSearchMacros.xml, I saw nothing that could allow this.

      Workaround for the wiki facet:

      window.addEventListener("DOMContentLoaded", function () {
        var facet = document.querySelector(".search-facet[data-name=wiki]");
        console.log("FACET", facet)
        if (facet) {
          facet.classList.add("expanded");
      {{  }}}
      })

      Attachments

        Activity

          People

            Unassigned Unassigned
            rjakse Raphaël Jakse
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated: