Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

affiliations: update value property to use id #269

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@ export const AffiliationsSuggestions = (creatibutors, isOrganization) => {

return {
text: creatibutor.name,
value: creatibutor.name,
value: creatibutor.id || creatibutor.name,
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it was changed back and forth several time, could you explain why is it needed?

Copy link
Member Author

Choose a reason for hiding this comment

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

The value prop was being used to set the selected value in the search input box, when for instance RWTH Aachen University was selected which was coming from two diff sources i.e. ror and edmo but had the same name in both, it selected both of them even if you click on one of them and the two entries would be selected in the input box as it was based on name which is not unique.

392781761-09d5e897-1efa-47a8-882b-de4bdee47687
392781760-93f9efa6-d167-4724-a3fd-09aa40f3fcd3

name: creatibutor.name,
extra: creatibutor,
id: creatibutor.id,
Expand Down
Loading