Skip to content

[DSpace-CRIS] Inverse Relations via Authority Framework (Frontend)#5134

Merged
tdonohue merged 11 commits intoDSpace:mainfrom
4Science:task/main/DURACOM-445
Mar 27, 2026
Merged

[DSpace-CRIS] Inverse Relations via Authority Framework (Frontend)#5134
tdonohue merged 11 commits intoDSpace:mainfrom
4Science:task/main/DURACOM-445

Conversation

@FrancescoMolinaro
Copy link
Copy Markdown
Contributor

@FrancescoMolinaro FrancescoMolinaro commented Feb 20, 2026

References

Description

Add new component for tabbed relations in item page.
The new relations are based on a scope parameter which represent the authority of the item in question.
Visually the component still uses the standard search page and is identical:

image

The new relations can be activated via a flag param in the default.app.config.ts, inside the item config:

showAuthorityRelations

if true the ui components will use the new authority based relations.

Instructions for Reviewers

List of changes in this PR:

Add new UI component for new scope/authority based relations

Include guidance for how to test or review your PR. This may include: steps to reproduce a bug, screenshots or description of a new feature, or reasons behind specific changes.

Checklist

This checklist provides a reminder of what we are going to look for when reviewing your PR. You do not need to complete this checklist prior creating your PR (draft PRs are always welcome).
However, reviewers may request that you complete any actions in this list if you have not done so. If you are unsure about an item in the checklist, don't hesitate to ask. We're here to help!

  • My PR is created against the main branch of code (unless it is a backport or is fixing an issue specific to an older branch).
  • My PR is small in size (e.g. less than 1,000 lines of code, not including comments & specs/tests), or I have provided reasons as to why that's not possible.
  • My PR passes ESLint validation using npm run lint
  • My PR doesn't introduce circular dependencies (verified via npm run check-circ-deps)
  • My PR includes TypeDoc comments for all new (or modified) public methods and classes. It also includes TypeDoc for large or complex private methods.
  • My PR passes all specs/tests and includes new/updated specs or tests based on the Code Testing Guide.
  • My PR aligns with Accessibility guidelines if it makes changes to the user interface.
  • My PR uses i18n (internationalization) keys instead of hardcoded English text, to allow for translations.
  • My PR includes details on how to test it. I've provided clear instructions to reviewers on how to successfully test this fix or feature.
  • If my PR includes new libraries/dependencies (in package.json), I've made sure their licenses align with the DSpace BSD License based on the Licensing of Contributions documentation.
  • If my PR includes new features or configurations, I've provided basic technical documentation in the PR itself.
  • If my PR fixes an issue ticket, I've linked them together.

@tdonohue tdonohue added new feature DSpace-CRIS merger This ticket/PR relates to the merger of DSpace-CRIS into DSpace. labels Feb 20, 2026
@tdonohue tdonohue moved this to 🙋 Needs Reviewers Assigned in DSpace 10.0 Release Feb 20, 2026
@tdonohue
Copy link
Copy Markdown
Member

tdonohue commented Feb 20, 2026

@FrancescoMolinaro : Could you specify which DSpace-CRIS differences this PR relates to? I think it's important to be clear to reviewers which features or architectural changes are in each PR, and it's unclear to me which one(s) this references

@FrancescoMolinaro FrancescoMolinaro marked this pull request as ready for review March 4, 2026 17:12
@artlowel artlowel requested a review from KevinVdV March 12, 2026 17:03
@github-actions
Copy link
Copy Markdown

Hi @FrancescoMolinaro,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@tdonohue
Copy link
Copy Markdown
Member

@FrancescoMolinaro : This appears to require backend PR DSpace/DSpace#11963 , so I've updated the description to note that

@tdonohue tdonohue changed the title [DSpace-CRIS] Porting of authority based relations components [DSpace-CRIS] Inverse Relations via Authority Framework (Frontend) Mar 13, 2026
Copy link
Copy Markdown
Member

@KevinVdV KevinVdV left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I made an initial review of this PR, I found 2 small issues, see details below.

Issue 1

The backend add support for the following pages to make use of this search box:

  • people
  • org units
  • projects,
    But in the PR the only place the ds-authority-related-entities-search is used is in the person entity.

Issue 2

The new authority framework UI component is enabled by default, this will cause with backwards compatibility. Can you modify the configuration so that the authority framework is optional (so it is the same as in the REST code)

@github-project-automation github-project-automation bot moved this from 🙋 Needs Reviewers Assigned to 👀 Under Review in DSpace 10.0 Release Mar 19, 2026
@FrancescoMolinaro
Copy link
Copy Markdown
Contributor Author

FrancescoMolinaro commented Mar 19, 2026

Hi @KevinVdV , thanks for the feedback, I have updated the item pages so that also OrgUnit and Projects have their configurations as on the backend.
In addition I have set the functionality to be disabled by default.

@KevinVdV
Copy link
Copy Markdown
Member

@FrancescoMolinaro Did you forget to push by any chance ? Cause there are no recent commits in this branch & the feature is still enabled by default.

@FrancescoMolinaro
Copy link
Copy Markdown
Contributor Author

Hi @KevinVdV yes I didn't realize my commit didn't pass through, now the PR should be up to date, thanks for the catch.

link: https://ror.org

# Enable authority based relations in item page
showAuthorithyRelations: false
Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@FrancescoMolinaro : I haven't fully reviewed/tested this PR, but I have an immediate question about this PR.

How does this showAuthorityRelations frontend setting relate to the new relationship.enable-virtual-metadata = true setting on the backend?

The reason I ask is that I'm trying to understand whether you always would want showAuthorityRelations to be set to true whenever relationship.enable-virtual-metadata is set to false. If so, then we might want to consider reading the value of relationship.enable-virtual-metadata from the backend in order to determine the correct behavior of the frontend.

But, if these configs are unrelated, then we definitely should keep both. I'm just trying to better understand if this PR requires relationship.enable-virtual-metadata=false or not.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @tdonohue, I think the property relationship.enable-virtual-metadata is necessary for the creation of the relations but not necessary to display existing ones, I am thinking a scenario in which the relations are created but then the feature gets disabled on the rest side.
This should be anyway an edge case and I agree that would be useful to have a single source of truth to enable/disable the feature.
We can maybe check along the rest PR if a new property would be necessary for the scope or we can assume the state of the relations feature from relationship.enable-virtual-metadata and ignore the edge case I mentioned.
I will run a check with @AdamF42 and come back as soon as possible.

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @tdonohue , after checking this with @AdamF42 , we think is best to not rely on the rest property relationship.enable-virtual-metadata as it would create an unnecessary dependency, the framework of the inverse relations is anyway active also if that property is set to false.

We believe that the best approach would be to keep the UI config param as on the rest side there isn't an actual toggle for the inverse relations. I would really appreciate to hear also your thoughts on this.

@tdonohue tdonohue requested a review from KevinVdV March 24, 2026 22:08
Copy link
Copy Markdown
Member

@tdonohue tdonohue left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@FrancescoMolinaro : I'm not understanding how to get this PR to work properly. I cannot seem to figure out how to get the tabbed display in your screenshot in the PR description.

Here's what I've done:

  1. I've installed this PR and the corresponding backend PR (leaving their default settings as-is)
  2. I've set relationship.enable-virtual-metadata = false on the backend and item > showAuthorityRelations: true on the frontend.
  3. I've created a single Publication which is linked to three authors (Person entities) via the authority framework.
  4. I've reindexed the site (./dspace index-discovery -b)
  5. Then I've visited the Item page for the Publication and also for the Person entities. I do not see the tabbed interface.

Am I misunderstanding how this should work? Could you please walk me through how to create some test data which is valid for this feature? Thanks!

Copy link
Copy Markdown
Member

@KevinVdV KevinVdV left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trying to review as well, I can get the tabs to show up but having trouble configuring the authority based entities for anything other than author / publications.

I'm using the following configuration, can you maybe tell me what I'm doing wrong ?

plugin.named.org.dspace.content.authority.ChoiceAuthority = \
 org.dspace.content.authority.OrcidAuthority = AuthorAuthority, \
 org.dspace.content.authority.ItemAuthority = ProjectAuthority,\
 org.dspace.content.authority.ItemAuthority = OrgUnitAuthority


cris.ItemAuthority.AuthorAuthority.entityType = Person
cris.ItemAuthority.AuthorAuthority.source = orcid

dc.relation.project: Research project (Project entity)
choices.plugin.dc.relation.project = ProjectAuthority
choices.presentation.dc.relation.project = suggest
authority.controlled.dc.relation.project = true

choices.plugin.dc.publisher = OrgUnitAuthority
choices.presentation.dc.publisher = suggest
authority.controlled.dc.publisher = true


person.affiliation.name: Person's affiliation (links to OrgUnit)
choices.plugin.person.affiliation.name = OrgUnitAuthority
choices.presentation.person.affiliation.name = suggest
authority.controlled.person.affiliation.name = true

@AdamF42
Copy link
Copy Markdown
Contributor

AdamF42 commented Mar 26, 2026

Trying to review as well, I can get the tabs to show up but having trouble configuring the authority based entities for anything other than author / publications.

I'm using the following configuration, can you maybe tell me what I'm doing wrong ?

plugin.named.org.dspace.content.authority.ChoiceAuthority = \
 org.dspace.content.authority.OrcidAuthority = AuthorAuthority, \
 org.dspace.content.authority.ItemAuthority = ProjectAuthority,\
 org.dspace.content.authority.ItemAuthority = OrgUnitAuthority


cris.ItemAuthority.AuthorAuthority.entityType = Person
cris.ItemAuthority.AuthorAuthority.source = orcid

dc.relation.project: Research project (Project entity)
choices.plugin.dc.relation.project = ProjectAuthority
choices.presentation.dc.relation.project = suggest
authority.controlled.dc.relation.project = true

choices.plugin.dc.publisher = OrgUnitAuthority
choices.presentation.dc.publisher = suggest
authority.controlled.dc.publisher = true


person.affiliation.name: Person's affiliation (links to OrgUnit)
choices.plugin.person.affiliation.name = OrgUnitAuthority
choices.presentation.person.affiliation.name = suggest
authority.controlled.person.affiliation.name = true

Hi @KevinVdV,
There was indeed a missing configuration in discovery.xml that prevented proper Project retrieval via authority. This has now been fixed.

Additionally, we've cleaned up all unused configurations for inverse relations to ensure consistency with the current changes.

Try with the following configuration:

# Named Authority Plugins
plugin.named.org.dspace.content.authority.ChoiceAuthority = \
 org.dspace.content.authority.OrcidAuthority = AuthorAuthority, \
 org.dspace.content.authority.ItemAuthority = ProjectAuthority,\
 org.dspace.content.authority.ItemAuthority = OrgUnitAuthority

choices.plugin.dc.relation.project = ProjectAuthority
choices.presentation.dc.relation.project = suggest
authority.controlled.dc.relation.project = true

choices.plugin.person.affiliation.name = OrgUnitAuthority
choices.presentation.person.affiliation.name = suggest
authority.controlled.person.affiliation.name = true

choices.plugin.dc.contributor.author = AuthorAuthority
choices.presentation.dc.contributor.author = suggest
authority.controlled.dc.contributor.author = true

cris.ItemAuthority.AuthorAuthority.source = orcid
cris.ItemAuthority.AuthorAuthority.entityType = Person
cris.ItemAuthority.ProjectAuthority.entityType = Project
cris.ItemAuthority.OrgUnitAuthority.entityType = OrgUnit

choices.plugin.project.investigator = AuthorAuthority
choices.presentation.project.investigator = suggest
authority.controlled.project.investigator = true

choices.plugin.dc.contributor.other = OrgUnitAuthority
choices.presentation.dc.contributor.other = suggest
authority.controlled.dc.contributor.other = true

choices.plugin.dc.description.sponsorship = OrgUnitAuthority
choices.presentation.dc.description.sponsorship = suggest
authority.controlled.dc.description.sponsorship = true

orcid.authority.prefix = will be generated::ORCID::

relationship.enable-virtual-metadata = false

Copy link
Copy Markdown
Member

@tdonohue tdonohue left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍 Thanks @FrancescoMolinaro ! I gave this another review and test today. After the fix to the configuration typo, everything is working great! I'm able to now see the new tabs on Person pages, OrgUnit pages, etc. I've mostly tested from the Person perspective, but everything is working well there, and I've verified OrgUnits are working at a basic level as well.

Flagging this as "needs documentation" since this feature will require docs to be added to the 10.0 docs at https://wiki.lyrasis.org/display/DSDOC10x

@tdonohue tdonohue moved this from 👀 Under Review to 👍 Reviewer Approved in DSpace 10.0 Release Mar 26, 2026
@tdonohue tdonohue added the needs documentation PR is missing documentation. All new features and config changes require documentation. label Mar 26, 2026
@tdonohue tdonohue requested a review from KevinVdV March 26, 2026 19:58
@tdonohue
Copy link
Copy Markdown
Member

@KevinVdV : Please rereview / retest this as soon as you can, as this is blocking several other DSpace-CRIS merger PRs. If there are outstanding issues you are finding, we can either ask to get them fixed quickly in this PR, or we can also consider creating follow-up bug tickets. Thanks!

@github-actions
Copy link
Copy Markdown

Hi @FrancescoMolinaro,
Conflicts have been detected against the base branch.
Please resolve these conflicts as soon as you can. Thanks!

@tdonohue
Copy link
Copy Markdown
Member

@FrancescoMolinaro : This PR also now has merge conflicts. If you could quickly rebase this one as well, I'd appreciate it. Thanks!

@KevinVdV
Copy link
Copy Markdown
Member

I did some further testing & was able to get the relationships to work, however I also found that the "Research Project" entity doesn't have the tabs yet (maybe a commit is missing because you mentioned you changed it: #5134 (comment))

What I did successfully test:

  • Person page showing:
    • Publications
    • Projects
  • Organizational Unit showing:
    • Researcher Projects
    • Researchers Publications
    • People
    • Projects

@tdonohue
Copy link
Copy Markdown
Member

@FrancescoMolinaro and @AdamF42 : It looks like these "Inverse Relations" PRs are really close to being merged. However, I can verify what @KevinVdV notes above is true: Person and OrgUnit entities work well with the tabs. But, Project entities are not displaying the tabs.

If necessary, we could move that to a follow-up bug ticket. But, if there's a quick fix that can be applied to these PRs, that'd also be great! Let us know if this is easy to fix or if we should log a bug ticket and fix this in a follow-up PR.

@FrancescoMolinaro
Copy link
Copy Markdown
Contributor Author

FrancescoMolinaro commented Mar 27, 2026

Hi @KevinVdV , @tdonohue , we removed the projects configurations, from frontend and backend, as we noticed they were based on metadata present only on CRIS and this would mean changing the default submission as well.
We thought it would be best to just reflect the default submission configuration as base functionality of this feature, sorry if I forgot to mention it.

We can always adapt the submission and relation at a later time to support also Projects, but I believe that would require a more general discussion.

I would really appreciate to hear your thoughts on this and thanks for the feedback!

@tdonohue
Copy link
Copy Markdown
Member

tdonohue commented Mar 27, 2026

@FrancescoMolinaro : Thanks for clarifying. Since that's expected behavior, this PR seems fine to me. Can you please rebase this PR though to fix the merge conflicts (so it can be merged)? There are also merge conflicts on #5145 that need to be fixed (so that it can be tested more easily)

UPDATE: I meant to also add that we should be sure to document that Projects don't have tabs yet. I'll create a bug ticket related to that known issue, and we can always close that ticket once this feature has been added. (Bug ticket created in #5318 )

@FrancescoMolinaro
Copy link
Copy Markdown
Contributor Author

Hi @tdonohue , conflicts on this one should be resolved, I'll align also #5145 asap.

Copy link
Copy Markdown
Member

@KevinVdV KevinVdV left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If we fix the project review later on a PR, I'm also at a +1

@tdonohue
Copy link
Copy Markdown
Member

@FrancescoMolinaro and @KevinVdV : I've created a bug ticket to capture this issue with the Project entities. See #5318. This is just to remind us that this needs to be fixed in a future PR.

@tdonohue
Copy link
Copy Markdown
Member

Merging as this is at +2. Thanks again @FrancescoMolinaro ! As with all other DSpace-CRIS merger PRs, I'm flagging this as "needs documentation" until docs can be added to https://wiki.lyrasis.org/display/DSDOC10x

@tdonohue tdonohue added this to the 10.0 milestone Mar 27, 2026
@tdonohue tdonohue merged commit 12818d5 into DSpace:main Mar 27, 2026
18 of 19 checks passed
@github-project-automation github-project-automation bot moved this from 👍 Reviewer Approved to ✅ Done in DSpace 10.0 Release Mar 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

DSpace-CRIS merger This ticket/PR relates to the merger of DSpace-CRIS into DSpace. needs documentation PR is missing documentation. All new features and config changes require documentation. new feature

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

[DSpace-CRIS] Inverse Relations via Authority Framework

4 participants