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

Import mdJSON function does not read dictionaryId #704

Open
hmaier-fws opened this issue Dec 17, 2024 · 1 comment
Open

Import mdJSON function does not read dictionaryId #704

hmaier-fws opened this issue Dec 17, 2024 · 1 comment
Assignees
Labels
bug Unexpected problem or unintended behavior !!Priority!! Needs to happen ASAP!

Comments

@hmaier-fws
Copy link
Contributor

hmaier-fws commented Dec 17, 2024

Issue

mdEditor Version (find version under settings): Production, https://github.com/adiwg/mdEditor/tree/405d949e

mdEditor Web Address (enter the URL):

Issue Description:

See also: #679

Importing a mdJSON does not read the data dictionary dictionaryId if present. The imported identifier should be used as are the other identifiers for metadata records and contacts.

Steps to reproduce (Bug reports only):

  1. Import a mdJSON file that contains a dataDictionary array with one or more dictionary objects
  2. Each dictionary object contains a dictionaryId (see example below)
  "dataDictionary": [
    {
      "dictionaryId": "dictionary UUID",
      "citation": {
        ...
      },
      ...
    }
  ]
}

Observed Results (Bug reports only):

  • The mdJSON file is imported without errors
  • The resulting dictionaries are displayed in the editor
  • When selecting a dictionary, the preview pane displays "Dictionary Id: Not Defined"
  • When viewing a dictionary in the "View Dictionaries" Dashboard, the "Preview JSON" function does display the imported dictionaryId

Expected Results (Bug reports only):

@hmaier-fws hmaier-fws added the bug Unexpected problem or unintended behavior label Dec 17, 2024
@hmaier-fws hmaier-fws changed the title Import mdJSON function does not write dictionaryId Import mdJSON function does not read dictionaryId Dec 17, 2024
@hmaier-fws
Copy link
Contributor Author

@dvonanderson full implementation of this will require a broader refactoring of the internal data model. See #705. But as an interim fix this can still be implemented since the mdJSON does not currently include identifiers, and any imported dictionaries are assigned null ID values.

On import of a mdJSON file, IF a dataDictionary.dictionaryId is present, then that value should be assigned to the mdEditor dictionaryId element.

@hmaier-fws hmaier-fws added the !!Priority!! Needs to happen ASAP! label Jan 4, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Unexpected problem or unintended behavior !!Priority!! Needs to happen ASAP!
Projects
None yet
Development

No branches or pull requests

2 participants