Skip to content

[Request a Correction] isWorkflowConfigured method does not work on migrated (<7.x) groups #534

@kskaiser

Description

@kskaiser

Describe the bug
For permitting to request a correction of an item, it is checked, if the item's collection has a workflow configured. This is accomplished by checking, if there's a group with a name based on a specific pattern:
It must start with COLLECTION_{uuid-of-the-collection}_WORKFLOW_ROLE, which works for workflows configured in a DSpace CRIS version >= 7.x.
For migrated collections and their workflow configurations the pattern when configuring a workflow step group name was:
COLLECTION_{id-of-the-collection}_WORKFLOW_STEP_{number-of-validation-step} (e.g., COLLECTION_21_WORKFLOW_STEP_2), but you were even allowed to edit the group name (to make it more meaningful).
Thus, the check fails and the method always returns false and the menu entry "Request a correction" is never available.

To Reproduce
Steps to reproduce the behavior:

  1. Having a migrated collection with a workflow configured; the name of the workflow group is not matching the pattern COLLECTION_{uuid-of-the-collection}_WORKFLOW_ROLE_...
  2. Having the Request a correction feature enabled (property item-correction.enabled set to true in dspace.cfg).
  3. Logged in as an admin user, you click on the ... button on an item page, but the dropdown menu is missing the menu entry "Request a correction".

Expected behavior
Logged in as an admin user and clicking on the dropdown menu ... of an item from a workflow-configured collection (at least one workflow step needs to be configured and the group created must not be empty), the menu entry "Request a correction" is visible and clickable leading to the edit form.

Related work
Link to any related tickets or PRs here.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions