Skip to content

fix(mydspace): keep Workflow tab after approve from view page (#181) - #194

Open
amadulhaxxani wants to merge 1 commit into
clarin-v7from
181-after-approving-workflow-item-user-is-redirected-to-your-submissions-instead-of-workflow-items
Open

amadulhaxxani wants to merge 1 commit into
clarin-v7from
181-after-approving-workflow-item-user-is-redirected-to-your-submissions-instead-of-workflow-items

Conversation

@amadulhaxxani

Copy link
Copy Markdown

Problem description

Approving a workflow item from its View page redirects to "Your submissions" instead of staying on "Workflow tasks".
Steps to reproduce: Workflow tasks tab → claim item → View → Approve.

Analysis

FullItemPageComponent.onWorkflowActionCompleted navigated to /mydspace with no configuration query param (full-item-page.component.ts:180), so MyDSpaceGuard fell back to the first available configuration, which is always workspace (my-dspace.guard.ts:44-51, role.service.ts:27,35). The fix passes configuration=workflow; the existing unit test in full-item-page.component.spec.ts was updated to match. Approving from the list itself never navigated, so it is unaffected. All claimed-task actions on the View page share this handler and now return to Workflow tasks.

Sync verification

N/A — no .json5 files changed.

Copilot review

  • Requested review from Copilot

Copilot AI balanced review requested due to automatic review settings October 26, 2026 11:23

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The focused fix matches the existing configuration contract and updates the regression assertion, with no blocking issues identified.

No open issues 🎉

What changed in this PR

Fixes the return navigation after a claimed-task action on the full item View page so users land on “Workflow tasks” rather than “Your submissions.”

Changes:

  • Adds configuration=workflow to the /mydspace navigation using the existing configuration enum.
  • Updates the regression test to assert the Workflow tab navigation parameters.
File Description
src/​app/​item-page/​full/​full-item-page.component.ts Returns users to Workflow tasks after a completed action.
src/​app/​item-page/​full/​full-item-page.component.spec.ts Updates the test name and expected navigation parameters.

Review effort: Balanced

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

After approving workflow item, user is redirected to Your submissions instead of Workflow Items

2 participants