SPO/7388 lang attributes in ddi export#7958
Conversation
Conflicts: src/main/java/edu/harvard/iq/dataverse/DatasetPage.java
may be uses that expects the raw value, but those should call getRawValue
|
Testing Status:
|
tracks mdLang if set, otherwise UI lang Conflicts: doc/sphinx-guides/source/installation/config.rst
|
OK, we're almost there! These are my test cases, please correct the technical details or otherwise provide feedback as needed :) Config scenarios: default, :Languages only, :MetadataLanguages+:Languages, :MetadataLanguages only
|
(no longer needed with the changes to other code)
What this PR does / why we need it: This PR adds xml:lang attributes to the DDI xml metadata export to improve compatibility with CESSDA's requirements. To support this, per Merce's preference, the PR adds a new metadata languages setting and a mechanism to let collection admins set the metadata language for new datasets (from the allowed list in the setting). The mechanism does not enforce using a specific language but does indicate the requested language when editing and again when metadata is displayed.
Which issue(s) this PR closes:
Closes #7388
Special notes for your reviewer: This is one of several PRs from Sciences PO work that increate i18n support. This PR is required for #6751 and should be reviewed/merged before the PR for that issue.
Suggestions on how to test this: Testing the basic mechanism should be simple - add a setting to list the allowed languages (e.g. {"English":"en", "French":"fr"} ) and verify that one can pick the language when editing a collection (edit/general info) and that a new dataset created in that collection uses that language and retains it even when the collection is changed to have a new choice. Publishing a dataset created this way should then allow checking that xml;:lang tags are added to the DDI XML output. The PR adds tags to the codebook element as well as the title, abstract, and distributor elements.
Does this PR introduce a user interface change? If mockups are available, please link/include them here: Yes - see description above.
Is there a release notes update needed for this change?:
Additional documentation:will document new setting in guide