Changes for page Context Search
Last modified by bougault on 2023/02/20 16:29
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -65,6 +65,7 @@ 65 65 this.nb = e.target.value; 66 66 } 67 67 handleSearch(textSearch) { 68 + console.log('search'); 68 68 if(this.searchText !== "" || textSearch) { 69 69 if(this.searchText !== this.prevSearchText) { 70 70 this.clearResults(); ... ... @@ -151,7 +151,7 @@ 151 151 } 152 152 customElements.define('clb-unified-search', UnifiedSearch); 153 153 154 - function handleXWikiSearch(searchString) { 155 + function handleXWikiSearch(searchString, offset, nb) { 155 155 return new Promise((resolve) => { 156 156 require(['jquery'], function($) { 157 157 const solrServiceURL = new XWiki.Document('SuggestSolrService', 'XWiki').getURL('get'); ... ... @@ -159,8 +159,8 @@ 159 159 $.get(solrServiceURL, { 160 160 outputSyntax: 'plain', 161 161 media: 'json', 162 - nb: 100,163 - offset: 10,163 + nb: nb, 164 + offset: offset, 164 164 query: [ 165 165 'q="__INPUT__"~100', 166 166 'fq=type:DOCUMENT',