Progress with OpenSearch tests with fuzzy search and wildcard
This commit is contained in:
parent
484be48d1e
commit
a853e93b68
2 changed files with 206 additions and 5 deletions
|
@ -88,7 +88,12 @@ export default class VsInput extends Vue {
|
|||
// };
|
||||
const suggestions = new Array<Suggestion>();
|
||||
|
||||
console.log("Display:", this.display);
|
||||
|
||||
this.results.forEach((dataset) => {
|
||||
|
||||
console.log("suggestions:foreach:", dataset.id);
|
||||
|
||||
// const del = dataset.title_output?.toLowerCase();
|
||||
if (dataset.title_output.toLowerCase().includes(this.display.toLowerCase())) {
|
||||
const title = dataset.title_output;
|
||||
|
@ -168,7 +173,7 @@ export default class VsInput extends Vue {
|
|||
}
|
||||
|
||||
private request(): void {
|
||||
console.log("searchTerm");
|
||||
console.log("request()");
|
||||
DatasetService.searchTerm(this.display, this.solr.core, this.solr.host).subscribe({
|
||||
next: (res: Dataset[]) => this.dataHandler(res),
|
||||
error: (error: string) => this.errorHandler(error),
|
||||
|
@ -178,6 +183,8 @@ export default class VsInput extends Vue {
|
|||
|
||||
private dataHandler(datasets: Dataset[]): void {
|
||||
this.results = datasets;
|
||||
// console.log(datasets);
|
||||
|
||||
// this.$emit("search", this.display);
|
||||
// this.loading = false;
|
||||
}
|
||||
|
|
Loading…
Add table
editor.link_modal.header
Reference in a new issue