Uploaded image for project: 'PUBLIC - Liferay Portal Community Edition'
  1. PUBLIC - Liferay Portal Community Edition
  2. LPS-51408

The fields of ddmStructureKey and ddmTemplateKey should use "KeywordAnalyzer"

    Details

      Description

      The fields of ddmStructureKey and ddmTemplateKey are desgined as NOT_ANALYZED in index. That is to say, these fields's value will be stored as a single term. However, the fileds were assigend to StandardAnalyzer and StandardAnalyzer will tokenizes for the two fields in search query. This does not match.

      Test Steps:
      1.Add the below code in FacetedSearcher.createFullQuery() {
      if (Validator.isNotNull(keywords))

      { ..... searchQuery.addTerms(Field.KEYWORDS, keywords); //add the bleow codes. searchQuery.addTerm("ddmStructureKey", keywords); }

      }

      2. Go to Search Portlet->Configuration, checked Display Main Query and then save.
      3. Search the keywords "Hello|World" in Search Portlet.
      Actual result: We will see "ddmStructureKey:hello ddmStructureKey:world" in query grammar.

      Expected behavior: We will see "ddmStructureKey:Hello|World" in query grammar.

        Attachments

          Issue Links

            Activity

              People

              • Votes:
                0 Vote for this issue
                Watchers:
                2 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved:
                  Days since last comment:
                  4 years, 4 weeks, 5 days ago

                  Packages

                  Version Package
                  6.2.X EE
                  7.0.0 M3