dataverse-client-javascript icon indicating copy to clipboard operation
dataverse-client-javascript copied to clipboard

Get Dataset Use Case hierarchy property persistentId missing

Open g-saracca opened this issue 1 year ago • 2 comments

Overview of the Feature Request

The response of the Get Dataset use case does not correctly send the persistentId of the dataset within the hierarchy property. Instead, it is sending the persistentId as an id property, and persistentId is being sent as undefined. See property hierarchy in the use case response.

{
    ...restOfProperties,
    
    "hierarchy": {
        "name": "Dataset from GS",
        "type": "dataset",
        "id": "doi:10.5072/FK2/WMJULU",
        "persistentId": undefined,
        "version": ":draft",
        "parent": {
            "name": "GS Dataverse",
            "type": "collection",
            "id": "gdataverse",
            "parent": {
                "name": "Root",
                "type": "collection",
                "id": "root"
            }
        }
    }
}

What Inspired the Request?

  • Behaviour found while working on https://github.com/IQSS/dataverse-frontend/issues/380

What Existing Behavior Do You Want Changed?

Correctly send persistentId property in hierarchy object of a dataset.

Any Brand New Behavior Do You Want to Add to js-dataverse?

None

Any Open or Closed Issues Related to This Feature Request?

Extend BreadcrumbsGenerator for action Items

g-saracca avatar May 16 '24 12:05 g-saracca

The bug was in the mapping code of the SPA, rather than in the js-dataverse use case. Here is a PR for the fix: https://github.com/IQSS/dataverse-frontend/pull/404

ekraffmiller avatar May 21 '24 21:05 ekraffmiller

Thanks @ekraffmiller!

g-saracca avatar May 22 '24 12:05 g-saracca

Issue resolved, closing

ekraffmiller avatar Sep 19 '24 13:09 ekraffmiller