Skip to content

Expose Collection guestbookRoot setting through API #12459

@ChengShi-1

Description

@ChengShi-1

Description
Image
After update the checkbox ⏫ , we should update the list of guestbook ⬇️
Image

The Manage Guestbooks page has a checkbox for including inherited/root guestbooks. In the Dataverse backend, this behavior is stored on the Collection object as the guestbookRoot field.
Currently, API clients do not appear to have a direct way to get or set this value. This makes it difficult for a frontend/API workflow to accurately mirror the Manage Guestbooks behavior or determine whether inherited guestbooks should be included.

Current Behavior
The JSF Manage Guestbooks page manages the setting through Dataverse.guestbookRoot.
The checkbox meaning is effectively the inverse of the backend field:
Include Guestbooks from Root = true -> guestbookRoot = false
Include Guestbooks from Root = false -> guestbookRoot = true
The dataset Edit Terms & Guestbook UI depends on this setting through:
Dataverse.getAvailableGuestbooks()
which uses guestbookRoot to decide whether parent/root guestbooks should be included.

Proposed Solution
Expose guestbookRoot through the Collection/Dataverse API.
Possible approaches:

  • Add guestbookRoot to the Collection object returned by existing get Collection APIs, and allow it to be updated through existing update Collection APIs.
  • Add a focused API for this setting
  • Follow what we did in Dataverse JSF, create an api GET /api/guestbooks/{dataverseAlias}/available returns available list of guestbook with includeInheritedGuestbooks update

Metadata

Metadata

Assignees

No one assigned

    Labels

    GREI Re-archIssues related to the GREI Dataverse rearchitectureSPAThese changes are required for the Dataverse SPASize: 10A percentage of a sprint. 7 hours.

    Type

    No type
    No fields configured for issues without a type.

    Projects

    Status
    SPRINT READY

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions