IQSS / IQSS/dataverse-frontend

Embargoed label missing on Dataset page

Open
#292 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

bug pm.GREI-d-2.7.1 pm.GREI-d-2.7.2
Dominant language
TypeScript
Stars
31
Forks
26
Avg merge
4d 13h
Merged PRs (30d)
4

Description

When a Dataset contains an embargoed file, the Embargoed Label is shown in the JSF version of the page, but not the SPA.
To reproduce

  1. Update your Dataverse instance to allow embargoes, for example:
    curl -X PUT -d 24 http://localhost:8000/api/admin/settings/:MaxEmbargoDurationInMonths
  2. Create a dataset in Draft mode
  3. Add a file to the dataset
  4. In the File Edit Options, choose embargo, and set and embargo date
  5. Publish the file
  6. For a logged in or not logged in user, the 'Embargoed' label should appear in the Dataset Page, and in the Dataset card on the Home Page.

JSF:
Screenshot 2024-01-29 at 5 16 49 PM

Screenshot 2024-01-29 at 4 50 38 PM SPA: Screenshot 2024-01-29 at 5 18 39 PM Screenshot 2024-01-29 at 4 51 24 PM

The embargo information is not returned from getDataset useCase, it's only in the file data, so it looks like this will require an update to js-dataverse library.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the SPA Dataset Page and the Dataset card on the Home Page, then trace the getDataset use case and the file data returned for embargoed files. Check the js-dataverse library boundary, since the issue notes that getDataset does not return embargo information. Done means the Embargoed label appears for logged-in and anonymous users in both SPA locations when a dataset contains an embargoed file.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, typescript
Domain
frontend
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.