From bf3e5d9b97bc47bfda4846e02af772a6967184e9 Mon Sep 17 00:00:00 2001 From: "argiro.kokogiannaki" Date: Thu, 13 May 2021 15:54:46 +0000 Subject: [PATCH] [Library|Trunk] -revert change filtering recent results with values <= current year git-svn-id: https://svn.driver.research-infrastructures.eu/driver/dnet40/modules/uoa-services-library/trunk/ng-openaire-library/src/app@61004 d315682c-612b-4755-9ff5-7f18f6832af3 --- services/searchResearchResults.service.ts | 1 - utils/fetchEntitiesClasses/fetchResearchResults.class.ts | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/services/searchResearchResults.service.ts b/services/searchResearchResults.service.ts index 29c53dce..9872d559 100644 --- a/services/searchResearchResults.service.ts +++ b/services/searchResearchResults.service.ts @@ -144,7 +144,6 @@ export class SearchResearchResultsService { url += "?format=json"; url += "&fq=" + params; url += "&sortBy=resultdateofacceptance,descending"; - url += "&fq=" + encodeURIComponent( "resultacceptanceyear <= " + (new Date()).getFullYear()); url += "&page=" + (page - 1) + "&size=" + size; return this.http.get((properties.useCache) ? (properties.cacheUrl + encodeURIComponent(url)) : url) diff --git a/utils/fetchEntitiesClasses/fetchResearchResults.class.ts b/utils/fetchEntitiesClasses/fetchResearchResults.class.ts index be80ca6d..cff53b97 100644 --- a/utils/fetchEntitiesClasses/fetchResearchResults.class.ts +++ b/utils/fetchEntitiesClasses/fetchResearchResults.class.ts @@ -47,7 +47,7 @@ export class FetchResearchResults { public getResultsForCommunity(resultType:string, communityId: string, page: number, size: number, properties:EnvProperties, contextId = null) { this.searchUtils.status = this.errorCodes.LOADING; - this.subscriptions.push(this._searchResearchResultsService.search(resultType, "", "&fq=" + encodeURIComponent( "resultacceptanceyear <= " + (new Date()).getFullYear()) + "&fq=communityid=" + communityId + (contextId?'&fq=categoryid=' + encodeURIComponent(contextId):''), page, size, "resultdateofacceptance,descending", [], properties).subscribe( + this.subscriptions.push(this._searchResearchResultsService.search(resultType, "", "&fq=communityid=" + communityId + (contextId?'&fq=categoryid=' + encodeURIComponent(contextId):''), page, size, "resultdateofacceptance,descending", [], properties).subscribe( data => { this.searchUtils.totalResults = data[0]; this.results = data[1];