Showing
1 changed file
with
7 additions
and
1 deletions
@@ -186,10 +186,16 @@ public class SearchExplainerService { | @@ -186,10 +186,16 @@ public class SearchExplainerService { | ||
186 | } | 186 | } |
187 | } | 187 | } |
188 | 188 | ||
189 | + for(SearchFieldResult searchFieldResult : resultList){ | ||
190 | + searchFieldResult.setTokens(Arrays.asList(StringUtils.join(searchFieldResult.getTokens(), ";"))); | ||
191 | + } | ||
192 | + | ||
193 | + | ||
189 | map.put("code", "200"); | 194 | map.put("code", "200"); |
190 | map.put("message", "show skn tokens"); | 195 | map.put("message", "show skn tokens"); |
191 | map.put("data", resultList); | 196 | map.put("data", resultList); |
192 | map.put("searchTokens", searchTokens); | 197 | map.put("searchTokens", searchTokens); |
198 | + | ||
193 | map.put("queryMatchResult", queryMatchResult); | 199 | map.put("queryMatchResult", queryMatchResult); |
194 | logger.info("End to show skn tokens. skn={}, keyword={}, cost={}.", skn, keyword, System.currentTimeMillis() - start); | 200 | logger.info("End to show skn tokens. skn={}, keyword={}, cost={}.", skn, keyword, System.currentTimeMillis() - start); |
195 | return map; | 201 | return map; |
@@ -206,7 +212,7 @@ public class SearchExplainerService { | @@ -206,7 +212,7 @@ public class SearchExplainerService { | ||
206 | String fieldValueStr = fieldValue != null ? fieldValue.toString() : null; | 212 | String fieldValueStr = fieldValue != null ? fieldValue.toString() : null; |
207 | List<String> tokens = getAnalyzerResult(fieldDesc, fieldValueStr); | 213 | List<String> tokens = getAnalyzerResult(fieldDesc, fieldValueStr); |
208 | searchFieldResult.setFieldValue(fieldValueStr); | 214 | searchFieldResult.setFieldValue(fieldValueStr); |
209 | - searchFieldResult.setTokens(Arrays.asList(StringUtils.join(tokens, ";"))); | 215 | + searchFieldResult.setTokens(tokens); |
210 | return searchFieldResult; | 216 | return searchFieldResult; |
211 | } | 217 | } |
212 | 218 |
-
Please register or login to post a comment