PASTAplus / DataPortal

EDI Data Portal
3 stars 3 forks source link

Update XSLT Logic to Display All EML Annotations as Hyperlinks in the Data Portal #148

Open clnsmth opened 5 days ago

clnsmth commented 5 days ago

Description

@twhiteaker reported an issue (thanks Tim!) with the display of attribute annotations in the EDI Data Portal. Currently, only annotations from the Ecosystem Ontology (ECSO) are hyperlinked to their respective URIs, while annotations from other ontologies (e.g., QUDT) are not. This inconsistency prevents users from easily accessing more information about non-ECSO annotations. The expected behavior is that all annotation labels should be hyperlinked to their respective URIs, regardless of the ontology.

Root Cause

The issue arises from an XSLT condition that checks if the URI contains the string 'purl' (see here). If it does, the annotation label is hyperlinked; if not, the hyperlink is omitted. This logic was initially implemented to ensure the legitimacy of URIs.

Proposed Solution

Since not all valid URIs contain 'purl', we recommend removing this condition. Instead, any validity checks for URIs should be handled by EDI’s EML Congruence Checker, allowing users to correct any invalid URIs before submitting their metadata.

Recommended Action

For now, the Data Portal's detailed metadata pages should always hyperlink the property and value labels with the propertyURI and valueURI of an EML annotation element, regardless of the URI's "validity". This ensures all annotations are treated equally while maintaining flexibility for future enhancements.

twhiteaker commented 5 days ago

Solution sounds good!

servilla commented 1 day ago

Both URIs for the value and property elements of annotations are now hyperlinked.