Repository navigation
[dtq-dev-93] Handle table paging after search, Curate button only for admins, workflow edit stuck on Loading - #1760
Open
milanmajchrak wants to merge 3 commits into
Open
milanmajchrak wants to merge 3 commits into
milanmajchrak wants to merge 3 commits into
Conversation
A search loads page 1, but the URL kept the old page, so the paginator showed a wrong range. The URL is replaced and only the latest load writes the rows. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The button opens the admin curation page, which only site administrators may open, so other reviewers got a 403 page. Co-Authored-By: Claude Opus 5.5 <[email protected]>
With a cached copy the edit form could start while the resolver's GET was still running. The form then read that response, which has no embedded collection, and stayed on "Loading". Co-Authored-By: Claude Opus 5.5 <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
References
Description
Three small fixes in admin and workflow pages. The handle table shows the right page range after a search, the Curate button shows only to users who may open the curation page, and Edit from MyDSpace no longer hangs on "Loading...".
Instructions for Reviewers
List of changes in this PR:
hdlpage in the URL to 1. Before, the results were page 1 but the URL stayed on page 2, so the paginator said "Now showing 11 - 1 out of 1 results". The URL is replaced, not pushed, because the search filter is not in the URL and Back could not restore it./admin/curation-tasks, and the admin routes let only site administrators in, so a reviewer got a 403 page.workflowItemPageResolverandworkspaceItemPageResolverno longer resolve from a cached copy. A workflow item expires from the cache after 10 s. After that, the resolver sent a new GET and resolved at once on the old copy, so the edit form started while that GET was running. The form then did not send its own request (same URL without embeds), got the resolver's response without the embedded collection, and failed onpayload.collection.id. Now the route waits for a fresh response.:idroute, so the View, Delete and Send back pages also do one extra GET.How to test:
/mydspace?configuration=workflow, wait 15 s, click Edit. The edit form opens. Before this PR it stayed on "Loading..." withTypeError ... reading 'id'in the console.npm run test -- --include=src/app/handle-page/handle-table/handle-table.component.spec.ts --include=src/app/shared/mydspace-actions/claimed-task/claimed-task-actions.component.spec.ts --include=src/app/workflowitems-edit-page/workflow-item-page.resolver.spec.ts --include=src/app/workspaceitems-edit-page/workspace-item-page.resolver.spec.tsCodex review (gpt-6.2-sol, high), 3 rounds: 4 findings fixed (older handle loads overwrote newer results, the search pushed a history entry, an edit-only resolver raced with the parent one). The last round found 2 more, not changed in this PR:
Checklist
mainbranch of code (unless it is a backport or is fixing an issue specific to an older branch).npm run lintnpm run check-circ-deps)package.json), I've made sure their licenses align with the DSpace BSD License based on the Licensing of Contributions documentation.🤖 Generated with Claude Code