Repository navigation
feat(disputes): add moderator resolution and role-aware read-only UI (#255) - #266
Merged
SudiptaPaul-31 merged 1 commit intoOct 22, 2026
Conversation
|
@Hustler490 Great news! 🎉 Based on an automated assessment of this PR, the linked Wave issue(s) no longer count against your application limits. You can now already apply to more issues while waiting for a review of this PR. Keep up the great work! 🚀 |
Contributor
Author
|
CI is waiting for maintainer approval ( Local checks:
The full |
Hustler490
force-pushed
the
feat/w2-issue-255-dispute-detail-ui
branch
from
October 22, 2026 02:13
72692da to
5a7d905
Compare
Collaborator
|
@Hustler490 good work LGTM |
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.
Closes #255
Summary
Completes the existing dispute details/resolution UI for issue #255 by closing the remaining resolution gaps: moderators can now record a final decision, the decision persists on the dispute, resolved disputes become read-only, and the UI knows whether the caller is an admin.
Problem
The dispute detail page already rendered the reason, evidence, timeline and resolution status, but:
POST /api/disputes/:id/resolveonly bumpedupdated_at; it never stored the resolution, status orresolved_aton the dispute./api/auth/mereturned no role, so the client could not distinguish an admin from a participant.Solution
status = 'resolved',resolution,resolved_at,updated_at), update the related job escrow state, and record adispute_resolvedactivity event.rolefrom/api/auth/me(additive field,nullif the user row cannot be read)./api/auth/mereportsrole === "admin"and the dispute is still open.Validation
npx vitest run "app/dashboard/disputes/[id]/page.test.tsx"ΓÇö 3 passed.npx eslint app/api/disputes/[id]/resolve/route.ts app/api/auth/me/route.ts app/dashboard/disputes/[id]/page.tsx app/dashboard/disputes/[id]/page.test.tsx components/navbar.tsxΓÇö 0 errors.npm run buildΓÇö success (39 routes generated).npm testsuite still has pre-existing failures in deliverables/reviews/recommendations tests unrelated to this change;mainCI (build+contracts) is green.Parallel-work check
No PR referencing #255 existed when work began or immediately before pushing. The other assigned issues already had open PRs (#202, #183, #412), and Savitools #431 was skipped because it was already fixed. This branch is based on current
main(73e5e9e).