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

Search for documents in default language when a document has no translation in the displayed language

    Details

    • Type: Improvement
    • Status: Open
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Labels:
      None
    • Difficulty:
      Unknown
    • Similar issues:

      Description

      Now the results are dependent of the current interface language.

      In a multilingual wiki if a page has no translation in one of the languages and the displayed language not the document's language no results will be displayed.

      A workaround is presented in XWIKI-9977 . So to make search display result when a document has no translation in the displayed language some changes have to be made:

      • In <server>/xwiki/bin/edit/Main/SolrSearchMacros uncomment the lines as described in XWIKI-9977
      • In <server>/xwiki/bin/edit/Main/SolrSearchConfig change, for the current language not to be selected in Search page
          'locale': ["$xcontext.locale", '']  

        to

         'locales': ["$xcontext.locale", ''] 
      • In <server>/xwiki/bin/edit/XWiki/SuggestSolrMacros comment the lines to display results in search suggest:
          #if (!$filterNames.contains('locales'))
            #set ($discard = $filterQuery.add("locale:(""$xcontext.locale"" OR """")"))
          #end 

      Add the possibility to configure it from administration.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              andreic Camelia Andrei
            • Votes:
              1 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:
                Date of First Response: