Package version (if known): latest (2.6.1 / master)
Describe the bug
If you are using a non-standard (not ORCID, ROR, or GND) identifier scheme in your names vocabulary, the identifier label does not display properly due to a typo in CreatibutorsModal.js. Instead, an orphaned colon prefixes the identifier (see screenshot).
I'm using a url identifier scheme and the identifier renders as (: https://...) when it should be (URL: https://....) e.g. identifier scheme label, then colon, then identifier. This is because line 211 of CreatibutorsModal.js contains a typo:
{identifier.scehme}: {identifier.identifier}
Steps to Reproduce
There are several steps to use a non-standard identifier scheme for names but I'll try to list them all.
Edit invenio.cfg and add a scheme to RDM_RECORDS_PERSONORG_SCHEMES and VOCABULARIES_NAMES_SCHEMES
# invenio.cfg
from idutils import is_url
from invenio_rdm_records.config import RDM_RECORDS_PERSONORG_SCHEMES
from invenio_vocabularies.config import VOCABULARIES_NAMES_SCHEMES
url_scheme = {
"label": _("URL"),
"validator": is_url,
"datacite": "URL",
}
RDM_RECORDS_PERSONORG_SCHEMES["url"] = url_scheme
VOCABULARIES_NAMES_SCHEMES["url"] = url_scheme
Create a names.yaml fixture with at least one name that uses this scheme
Reviewing the code, it wouldbe preferable if the scheme's label could be used here, but identifier.scheme is just a string referencing the scheme, identifier.scheme.label doesn't work.
Package version (if known): latest (2.6.1 / master)
Describe the bug
If you are using a non-standard (not ORCID, ROR, or GND) identifier scheme in your names vocabulary, the identifier label does not display properly due to a typo in CreatibutorsModal.js. Instead, an orphaned colon prefixes the identifier (see screenshot).
I'm using a
url
identifier scheme and the identifier renders as(: https://...)
when it should be(URL: https://....)
e.g. identifier scheme label, then colon, then identifier. This is because line 211 of CreatibutorsModal.js contains a typo:Steps to Reproduce
There are several steps to use a non-standard identifier scheme for names but I'll try to list them all.
RDM_RECORDS_PERSONORG_SCHEMES
andVOCABULARIES_NAMES_SCHEMES
Expected behavior
Autocompleted name renders as "Phetteplace, Eric (URL: https://portal.cca.edu/people/ephetteplace)". Instead, the "URL" label is absent.
Screenshots (if applicable)
Additional context
PR incoming. FIxing the typo should be enough. Change shouldn't affect much else.