diff --git a/service/src/main/inse/persons/logic.py b/service/src/main/inse/persons/logic.py index 96823228..c56a9630 100644 --- a/service/src/main/inse/persons/logic.py +++ b/service/src/main/inse/persons/logic.py @@ -42,7 +42,7 @@ VERIFIED_PERSONS_INDEX = "orgminer_verified_persons_ude" VERIFIED_PERSONS_INSTITUTION_ID = DEFAULT_INSTITUTION_ID VERIFIED_PERSON_FIELDS = [ "openalex_id", - "org_name", + "organization", "org_uri", "org_hierarchy_path", "verified_at", @@ -73,7 +73,7 @@ async def get_verified_organizations(author_id: str) -> list[VerifiedOrganizatio }, "sort": [ {"verified_at": {"order": "desc", "missing": "_last"}}, - {"org_name.keyword": {"order": "asc", "missing": "_last"}}, + {"organization.keyword": {"order": "asc", "missing": "_last"}}, ], } @@ -91,7 +91,7 @@ async def get_verified_organizations(author_id: str) -> list[VerifiedOrganizatio for hit in data.get("hits", {}).get("hits", []): source = hit.get("_source") or {} org_uri = normalize_org_uri(source.get("org_uri")) - org_name = (source.get("org_name") or "").strip() + org_name = (source.get("organization") or "").strip() key = org_uri or org_name.casefold() if not key: continue diff --git a/webapp/src/app/modules/person/person.component.html b/webapp/src/app/modules/person/person.component.html index 2fafa6f6..4ff243d5 100644 --- a/webapp/src/app/modules/person/person.component.html +++ b/webapp/src/app/modules/person/person.component.html @@ -1,217 +1,231 @@ -@if (!isPersonLoading()) { -
-
-
{{ initials() }}
-
-
- Person -

{{ displayName() }}

- -
- @if (resolvedInstitution() || verifiedOrganizations().length > 0) { -
- @if (resolvedInstitution(); as inst) { - - @if (secondaryInstitutions().length > 0) { - + @if (!isPersonLoading()) { +
+
+
{{ initials() }}
+
+
+ Person +

{{ displayName() }}

+ +
+ @if ( + resolvedInstitution() || + (canOpenVerifiedOrganizationHierarchy() && + verifiedOrganizations().length > 0) + ) { +
+ @if (resolvedInstitution(); as inst) { + + @if (secondaryInstitutions().length > 0) { + + } } - } - @for (org of verifiedOrganizations(); track $index) { - @if (canOpenOrganizationHierarchy(org)) { - + } @else { + + {{ VERIFIED_ICON }} + {{ org.org_name }} + + } + } + } +
+ } + @if ( + worksCount() !== null || + citedByCount() !== null || + h_index() !== null + ) { + + @if (worksCount() !== null) { + + {{ PUBLICATION_ICON }} + {{ worksCount() | number }} Publikationen + + } + @if (worksCount() !== null && citedByCount() !== null) { + · + } + @if (citedByCount() !== null) { + + {{ CITATION_ICON }} + {{ citedByCount() | number }} Zitationen + + } + @if ( + (worksCount() !== null || citedByCount() !== null) && + h_index() !== null + ) { + · + } + @if (h_index() !== null) { + - {{ VERIFIED_ICON }} - {{ org.org_name }} - - } @else { - + {{ TRENDING_UP_ICON }} + h-Index {{ h_index() }} + + } + + } + @if (displayCareerStage() || orcid()) { +
+ + @if (orcid(); as orcidId) { + {{ VERIFIED_ICON }} - {{ org.org_name }} - + {{ orcidId }} + } - } -
- } - @if ( - worksCount() !== null || citedByCount() !== null || h_index() !== null - ) { - - @if (worksCount() !== null) { - - {{ PUBLICATION_ICON }} - {{ worksCount() | number }} Publikationen - - } - @if (worksCount() !== null && citedByCount() !== null) { - · - } - @if (citedByCount() !== null) { - - {{ CITATION_ICON }} - {{ citedByCount() | number }} Zitationen - - } - @if ( - (worksCount() !== null || citedByCount() !== null) && - h_index() !== null - ) { - · - } - @if (h_index() !== null) { +
+ } +
+
+ + +
+ @if (this.links()) { + + } + } @else { + + } + + @let activeLink = this.activeLink(); + @if (activeLink) { +
+ @if (activeLink.label) { +
{{ activeLink.label }}
} - @if (displayCareerStage() || orcid()) { -
- - @if (orcid(); as orcidId) { - - {{ VERIFIED_ICON }} - {{ orcidId }} - - } -
+ @if (activeLink.description) { + {{ activeLink.description }} }
+ } +
+
- - - - @if (this.links()) { - - } -} @else { - -} - - @let activeLink = this.activeLink(); - @if (activeLink) { -
- @if (activeLink.label) { -
{{ activeLink.label }}
- } - @if (activeLink.description) { - {{ activeLink.description }} - } -
- } -
- -
-
+
diff --git a/webapp/src/app/modules/person/person.component.ts b/webapp/src/app/modules/person/person.component.ts index f69feef5..7e186294 100644 --- a/webapp/src/app/modules/person/person.component.ts +++ b/webapp/src/app/modules/person/person.component.ts @@ -79,9 +79,7 @@ import { import { PageContainerComponent } from '../../shared/ui/page-container/page-container.component'; /** Accepts raw and full-URL OpenAlex IDs, e.g. `I123` or `.../I123`. */ -const normalizeInstitutionId = ( - value: string | null | undefined, -): string => +const normalizeInstitutionId = (value: string | null | undefined): string => (value ?? '') .trim() .replace(/^https:\/\/openalex\.org\//i, '')