Fix parenthesis bug in search queries

This commit is contained in:
Konstantinos Triantafyllou 2022-09-09 12:13:01 +03:00
parent 2261f4ae6f
commit 16fd671a5c
1 changed files with 2 additions and 2 deletions

View File

@ -6,7 +6,7 @@ import {
OnChanges, OnChanges,
OnDestroy, OnDestroy,
OnInit, OnInit,
Output, SimpleChanges, SimpleChanges,
ViewChild ViewChild
} from '@angular/core'; } from '@angular/core';
import {Location} from '@angular/common'; import {Location} from '@angular/common';
@ -985,7 +985,7 @@ export class NewSearchPageComponent implements OnInit, OnDestroy, OnChanges {
} }
} }
if (doisParams.length > 0) { if (doisParams.length > 0) {
params += this.createQuotedKeywordQuery(value, id, operatorId, countParams, true, true, includes) + (includes?(" or " + doisParams + ")"):")"); params += this.createQuotedKeywordQuery(value, id, operatorId, countParams, true, true, includes) + " or " + doisParams;
} else { } else {
//if it is PIDs but no doisquery produced, forced to use quotes as the query will fail due to special characters //if it is PIDs but no doisquery produced, forced to use quotes as the query will fail due to special characters
params += this.createQuotedKeywordQuery(value, id, operatorId, countParams, true, params += this.createQuotedKeywordQuery(value, id, operatorId, countParams, true,