Skip to content

M9-S4b: seller listing management write operations#108

Merged
erikshafer merged 1 commit into
mainfrom
m9-s4b-seller-listing-management
Jun 13, 2026
Merged

M9-S4b: seller listing management write operations#108
erikshafer merged 1 commit into
mainfrom
m9-s4b-seller-listing-management

Conversation

@erikshafer

Copy link
Copy Markdown
Owner

Summary

  • Create-draft form at /listings/new — 10-field form with react-hook-form + Zod validation; Flash/Timed conditional duration visibility; extended-bidding toggle with conditional trigger-window/extension fields; duration presets dropdown (1h–7d); shouldUnregister: true for clean conditional field handling
  • Edit-draft dialog — modal overlay on Draft-status listing cards; 3 mutable fields (title, reservePrice, buyItNowPrice) pre-populated from current values; PUT /api/selling/listings/draft
  • Submit-for-publication button — on Draft-status listings; POST /api/selling/listings/submit; auto-approval chain transitions to Published immediately
  • Mutation hooksuseCreateDraft, useEditDraft, useSubmitListing with TanStack Query invalidation on success
  • shadcn/ui additions — Input, Label, Select, Checkbox components
  • 35 new tests — form schema validation (17), create-listing page (7), mutation payload transformation (4), listings page actions (7); seller total 55 (was 20)
  • Live HTTP smoke — full journey verified: session → register → create Flash draft → query → edit → submit → Published → create Timed draft (7-day duration) → submit → 2 Published listings

Zero backend changes. Bidder (25) and ops (47) test baselines unchanged.

Test plan

  • npm run build — seller app builds clean (tsc + vite)
  • Seller Vitest: 55 pass (was 20, +35)
  • Bidder Vitest: 25 pass (unchanged)
  • Ops Vitest: 47 pass (unchanged)
  • .NET build: 0 errors, 2 warnings (baseline)
  • .NET tests: 326 pass (untouched)
  • Live HTTP smoke against Aspire: create → edit → submit for both Flash and Timed
  • CI green

Create-draft form at /listings/new with 10 fields (react-hook-form + Zod),
Flash/Timed conditional visibility, extended-bidding toggle; edit-draft
dialog on Draft-status listings (3 mutable fields); submit-for-publication
button; mutation hooks with TanStack Query invalidation; 35 new tests
(seller total: 55); shadcn/ui Input, Label, Select, Checkbox added;
live HTTP smoke verified full journey (create → edit → submit → Published
for both Flash and Timed formats). Zero backend changes.
@erikshafer erikshafer self-assigned this Jun 13, 2026
@erikshafer erikshafer merged commit a8a886c into main Jun 13, 2026
6 checks passed
@erikshafer erikshafer deleted the m9-s4b-seller-listing-management branch June 13, 2026 17:24
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.

1 participant