From afdf6bf9648d4b4cfebeb848286c7fb80a585dd0 Mon Sep 17 00:00:00 2001 From: argirok Date: Thu, 18 Apr 2024 11:08:41 +0300 Subject: [PATCH 1/4] [develop | DONE | CHANGED] in filters use "publication", "software", "dataset", "other" table instead of the result one --- monitor/entities/stakeholder.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/monitor/entities/stakeholder.ts b/monitor/entities/stakeholder.ts index a1670174..75b88d74 100644 --- a/monitor/entities/stakeholder.ts +++ b/monitor/entities/stakeholder.ts @@ -296,7 +296,7 @@ export class IndicatorFilterUtils { } static getFieldForTable(field, table){ if(["publication", "software", "dataset", "other", "result"].indexOf(table)!=-1 && IndicatorFilterUtils.filteredFields[field]["result"]){ - return IndicatorFilterUtils.filteredFields[field]["result"]; + return IndicatorFilterUtils.filteredFields[field]["result"].replace("result.",table + "."); }else{ return IndicatorFilterUtils.filteredFields[field][table]; } From 474a73e2f791abdfd354471f8be27af204008f7b Mon Sep 17 00:00:00 2001 From: argirok Date: Thu, 18 Apr 2024 15:08:17 +0300 Subject: [PATCH 2/4] [develop | DONE | CHANGED] indicator utils: user date range overrides the default range a chart may have --- monitor-admin/utils/indicator-utils.ts | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/monitor-admin/utils/indicator-utils.ts b/monitor-admin/utils/indicator-utils.ts index 41ecbea3..3e76c8fc 100644 --- a/monitor-admin/utils/indicator-utils.ts +++ b/monitor-admin/utils/indicator-utils.ts @@ -554,11 +554,11 @@ export class IndicatorUtils { filterApplied = true; } else if (filterType == "start_year" || filterType == "end_year") { //if has date filter already - if (filterType == "start_year" && parseInt(filterValue) > parseInt(queries["query"]["filters"][filterposition.filter]['groupFilters'][filterposition.groupFilter]["values"][0])) { + // if (filterType == "start_year" && parseInt(filterValue) > parseInt(queries["query"]["filters"][filterposition.filter]['groupFilters'][filterposition.groupFilter]["values"][0])) { queries["query"]["filters"][filterposition.filter]['groupFilters'][filterposition.groupFilter]["values"][0] = filterValue; - } else if (filterType == "end_year" && parseInt(filterValue) < parseInt(queries["query"]["filters"][filterposition.filter]['groupFilters'][filterposition.groupFilter]["values"][0])) { + // } else if (filterType == "end_year" && parseInt(filterValue) < parseInt(queries["query"]["filters"][filterposition.filter]['groupFilters'][filterposition.groupFilter]["values"][0])) { queries["query"]["filters"][filterposition.filter]['groupFilters'][filterposition.groupFilter]["values"][0] = filterValue; - } + // } filterApplied = true; } } else { From 68125b35774dddea903732074f206ade9311dbbd Mon Sep 17 00:00:00 2001 From: argirok Date: Fri, 19 Apr 2024 12:09:00 +0300 Subject: [PATCH 3/4] [develop | DONE | CHANGED] Claims: keep both shortname and funderName, in cards show fundername. For unidentified, hide code and link --- claims/claim-utils/claimHelper.class.ts | 1 + claims/claim-utils/claimProjectSearchForm.component.ts | 5 +++-- claims/directLinking/directLinking.component.ts | 1 + claims/linking/insertClaim/insertClaim.component.ts | 2 +- .../selected/ClaimEntityProjectMetadata.component.ts | 6 +++--- services/servicesUtils/refineResults.class.ts | 2 +- utils/entitiesAutoComplete/entitySearch.service.ts | 3 ++- 7 files changed, 12 insertions(+), 8 deletions(-) diff --git a/claims/claim-utils/claimHelper.class.ts b/claims/claim-utils/claimHelper.class.ts index 74349800..d3fb38f4 100644 --- a/claims/claim-utils/claimHelper.class.ts +++ b/claims/claim-utils/claimHelper.class.ts @@ -28,6 +28,7 @@ export class ClaimResult { export class ClaimProject { public funderId: string; + public funderShortname: string; public funderName: string; public acronym: string; public startDate: string; diff --git a/claims/claim-utils/claimProjectSearchForm.component.ts b/claims/claim-utils/claimProjectSearchForm.component.ts index 27ec74d5..70b154e6 100644 --- a/claims/claim-utils/claimProjectSearchForm.component.ts +++ b/claims/claim-utils/claimProjectSearchForm.component.ts @@ -178,9 +178,10 @@ export class ClaimProjectsSearchFormComponent { const entity: ClaimEntity = new ClaimEntity(); entity.project = new ClaimProject(); entity.project.funderId = item.funderId; - entity.project.funderName = item.funderShortname; + entity.project.funderShortname = item.funderShortname?item.funderShortname:(entity.project.funderId.split("::")[1]); + entity.project.funderName = item.funderName; entity.id = item.id; - entity.project.url = properties.searchLinkToProject + entity.id; + entity.project.url = (item.code !="unidentified") ? properties.searchLinkToProject + entity.id : null; entity.title = item.title.name; entity.project.acronym = item.acronym; entity.project.startDate = item.startYear; diff --git a/claims/directLinking/directLinking.component.ts b/claims/directLinking/directLinking.component.ts index 3fcd7537..70d46032 100644 --- a/claims/directLinking/directLinking.component.ts +++ b/claims/directLinking/directLinking.component.ts @@ -156,6 +156,7 @@ export class DirectLinkingComponent { entity.project.code = project.code; entity.project.endDate = project.endDate; entity.project.funderId = project.funderId; + entity.project.funderShortname = project.funderShortName?project.funderShortName:(entity.project.funderId.split("::")[1]); entity.project.funderName = project.funderName; entity.project.fundingLevel0 = project.fundingLevel0; entity.project.jurisdiction = project.jurisdiction; diff --git a/claims/linking/insertClaim/insertClaim.component.ts b/claims/linking/insertClaim/insertClaim.component.ts index 05615ba9..0cf983e5 100644 --- a/claims/linking/insertClaim/insertClaim.component.ts +++ b/claims/linking/insertClaim/insertClaim.component.ts @@ -508,7 +508,7 @@ export class ClaimInsertComponent { entity["linksToProjects"] = []; } let project: ClaimEntity = results[i]; - entity["linksToProjects"].push("info:eu-repo/grantAgreement/" + project.project.funderName + "/" + project.project.fundingLevel0 + "/" + project.project.code + "/" + project.project.jurisdiction + "/" + project.title + "/" + project.project.acronym); + entity["linksToProjects"].push("info:eu-repo/grantAgreement/" + project.project.funderShortname + "/" + project.project.fundingLevel0 + "/" + project.project.code + "/" + project.project.jurisdiction + "/" + project.title + "/" + project.project.acronym); } else if (results[i].context) { diff --git a/claims/linking/selected/ClaimEntityProjectMetadata.component.ts b/claims/linking/selected/ClaimEntityProjectMetadata.component.ts index 0b90acc6..229ebeca 100644 --- a/claims/linking/selected/ClaimEntityProjectMetadata.component.ts +++ b/claims/linking/selected/ClaimEntityProjectMetadata.component.ts @@ -16,10 +16,10 @@ import {ClaimEntity} from '../../claim-utils/claimHelper.class';
-
- Funder: {{entity.project.funderName}} +
+ Funder: {{entity.project.funderName?entity.project.funderName:entity.project.funderShortname}}
-
+
Project Code: {{entity.project.code}}
diff --git a/services/servicesUtils/refineResults.class.ts b/services/servicesUtils/refineResults.class.ts index dcd48d17..dd802f32 100644 --- a/services/servicesUtils/refineResults.class.ts +++ b/services/servicesUtils/refineResults.class.ts @@ -70,7 +70,7 @@ export class RefineResultsUtils { } public static inParenthesisThePartAfterCharacters(field, characters):string { if( field.name.indexOf(characters) !=-1){ - return field.name.split(characters)[0]+" ("+field.name.split(characters)[1]+")"; + return field.name.split(characters)[0]+ (field.name.split(characters)[1]?(" ("+field.name.split(characters)[1]+")"):""); } return field.name; diff --git a/utils/entitiesAutoComplete/entitySearch.service.ts b/utils/entitiesAutoComplete/entitySearch.service.ts index f7cc9478..5580445f 100644 --- a/utils/entitiesAutoComplete/entitySearch.service.ts +++ b/utils/entitiesAutoComplete/entitySearch.service.ts @@ -237,7 +237,8 @@ private fetch (link,id,oafEntityType,type, properties:EnvProperties ){ if(resData['fundingtree'] && resData['fundingtree']['funder']){ value.funderId = (resData['fundingtree']['funder']['id'] )?resData['fundingtree']['funder']['id']:""; - value.funderName = (resData['fundingtree']['funder']['shortname'] )?resData['fundingtree']['funder']['shortname']:""; + value.funderName = (resData['fundingtree']['funder']['name'] )?resData['fundingtree']['funder']['name']:""; + value.funderShortName = (resData['fundingtree']['funder']['shortname'] )?resData['fundingtree']['funder']['shortname']:""; value.jurisdiction = (resData['fundingtree']['funder']['jurisdiction'] )?resData['fundingtree']['funder']['jurisdiction']:""; if(resData['fundingtree']['funding_level_2']){ value.fundingLevel0 = (resData['fundingtree']['funding_level_2'] && resData['fundingtree']['funding_level_2']['parent'] && From ce87f0690df1877d6e08c3b769f79aa57e96cd70 Mon Sep 17 00:00:00 2001 From: "konstantina.galouni" Date: Mon, 22 Apr 2024 17:14:46 +0300 Subject: [PATCH 4/4] [develop | DONE | FIXED]: BUG fixes in orcid author modal | BUG fixes in search filters column. 1. mobile-dropdown.component.ts: Added makrForCheck() method call in "open()". 2. deletedByInference.component.ts: Added @Input() isMobile: boolean = false; & In set parameter [isMobile]="isMobile". 3. resultLanding.component.html: In mobile view, in set parameters [isMobile]="isMobile" and [modal]="alertModalDeletedByInferenceFS". 4. showAuthors.component.ts: 5. searchOrganizations.component.ts: [BUG FIX] In set parameter [showRefine]="refineFields?.length > 0" to display filters or not. 6. newSearchPage.component.html: [BUG FIX] Updated checks for displaying refine filters column or not. --- .../deletedByInference.component.ts | 3 ++- .../result/resultLanding.component.html | 16 ++++++++++++---- searchPages/searchOrganizations.component.ts | 1 + .../searchUtils/newSearchPage.component.html | 10 ++++++++-- utils/authors/showAuthors.component.ts | 17 ++++++++++------- .../mobile-dropdown.component.ts | 1 + 6 files changed, 34 insertions(+), 14 deletions(-) diff --git a/landingPages/result/deletedByInference/deletedByInference.component.ts b/landingPages/result/deletedByInference/deletedByInference.component.ts index 30ebb017..b986c240 100644 --- a/landingPages/result/deletedByInference/deletedByInference.component.ts +++ b/landingPages/result/deletedByInference/deletedByInference.component.ts @@ -28,7 +28,7 @@ import {HelperFunctions} from "../../../utils/HelperFunctions.class";
  • + [isDeletedByInferenceModal]="true" [isMobile]="isMobile">
  • + [resultType]="type" [type]="openaireEntities.PUBLICATIONS" + [isMobile]="isMobile" + [modal]="alertModalDeletedByInferenceFS"> + [resultType]="'dataset'" [type]="openaireEntities.DATASETS" + [isMobile]="isMobile" + [modal]="alertModalDeletedByInferenceFS"> + [resultType]="type" [type]="openaireEntities.SOFTWARE" + [isMobile]="isMobile" + [modal]="alertModalDeletedByInferenceFS"> + [resultType]="'other'" [type]="openaireEntities.OTHER" + [isMobile]="isMobile" + [modal]="alertModalDeletedByInferenceFS"> diff --git a/searchPages/searchOrganizations.component.ts b/searchPages/searchOrganizations.component.ts index 415ee722..45c49dcc 100644 --- a/searchPages/searchOrganizations.component.ts +++ b/searchPages/searchOrganizations.component.ts @@ -33,6 +33,7 @@ import {RefineFieldResultsService} from "../services/refineFieldResults.service" [includeOnlyResultsAndFilter]="includeOnlyResultsAndFilter" [searchForm]="searchForm" [sort]="false" + [showRefine]="refineFields?.length > 0" [filters]="filters" [simpleView]="simpleView" formPlaceholderText="Search by organization name..." [showSwitchSearchLink]="showSwitchSearchLink" diff --git a/searchPages/searchUtils/newSearchPage.component.html b/searchPages/searchUtils/newSearchPage.component.html index c623abc1..f5349f5d 100644 --- a/searchPages/searchUtils/newSearchPage.component.html +++ b/searchPages/searchUtils/newSearchPage.component.html @@ -288,8 +288,14 @@
    -
    + + + + + + +
    diff --git a/utils/authors/showAuthors.component.ts b/utils/authors/showAuthors.component.ts index eccccd6f..0269c95c 100644 --- a/utils/authors/showAuthors.component.ts +++ b/utils/authors/showAuthors.component.ts @@ -19,7 +19,7 @@ import {properties} from "../../../../environments/environment"; @Component({ selector: 'showAuthors', template: ` - + {{author.fullName + ";"}} @@ -36,7 +36,7 @@ import {properties} from "../../../../environments/environment";
    + uk-dropdown="mode:click; offset: 4;" style="min-width: 465px !important;" [attr.container]="modal ? false : true">
    @@ -112,7 +112,7 @@ import {properties} from "../../../../environments/environment"; + *ngTemplateOutlet="author_template; context: { author: author, i:i, italic: true, modal: modal}"> +{{authors.length - authorsLimit | number}} more @@ -127,18 +127,18 @@ import {properties} from "../../../../environments/environment";
    - +
    - +
    - +
    - +
    @@ -174,6 +174,9 @@ export class ShowAuthorsComponent { if (this.modal) { this.modal.cancel(); } + if(this.authorsModal) { + this.authorsModal.cancel(); + } } public viewAllClick() { diff --git a/utils/mobile-dropdown/mobile-dropdown.component.ts b/utils/mobile-dropdown/mobile-dropdown.component.ts index d7ce6e3f..db944564 100644 --- a/utils/mobile-dropdown/mobile-dropdown.component.ts +++ b/utils/mobile-dropdown/mobile-dropdown.component.ts @@ -56,6 +56,7 @@ export class MobileDropdownComponent implements OnInit{ parent.removeChild(this.element.nativeElement); container.append(this.element.nativeElement); this.opened = true; + this.cdr.markForCheck(); body.setAttribute('style', 'overflow-y: hidden'); } }